We consider a metric model of 4-space with the conformai Weyl parameter depending on the state of the charged matter. We show that there exists a version of the theory that allows unification of gravitation and electrodynamics based on geometry with an additional dynamical connection. We give equations for geodesies, curvature tensors, and the Ricci and scalar curvatures. Within the framework of the model, we obtain the Einstein equations as well as Maxwell-type equations that contain a nonlinearity analogous to the nonlinearity of the Einstein equations. We find an exact solution for the case of a static, homogeneous spherical charge distribution. The internal solution has a region of singular attraction and repulsion of like-charged matter.