Einstein started with the constant speed of light as a postulate in 1905 when he was doing special relativity, but by 1911 he was getting into general relativity. That's when he wrote On the Influence of Gravitation on the Propagation of Light, where he said this:
Einstein wrote:If we call the velocity of light at the origin of co-ordinates co, then the velocity of light c at a place with the gravitation potential Φ will be given by the relation c = co(1 + Φ/c²).
This is the speed of light varying with gravitational potential. It wasn't a one-off, because in 1912 he said it again when he wrote "On the other hand I am of the view that the principle of the constancy of the velocity of light can be maintained only insofar as one restricts oneself to spatio-temporal regions of constant gravitational potential". He repeated this in 1913 when he said: "I arrived at the result that the velocity of light is not to be regarded as independent of the gravitational potential. Thus the principle of the constancy of the velocity of light is incompatible with the equivalence hypothesis". Here it is again in Die Relativitätstheorie in 1915 where he says "the writer of these lines is of the opinion that the theory of relativity is still in need of generalization, in the sense that the principle of the constancy of the velocity of light is to be abandoned."
That’s on page 259 of Doc 21, see the Princeton bibliography for a list. He says it again in late 1915, on page 150 of Doc 30, within The Foundation of the General Theory of Relativity. Einstein says "the principle of the constancy of the velocity of light in vacuo must be modified." He really spells it out in section 22 of the 1916 book Relativity: The Special and General Theory:
Einstein wrote:In the second place our result shows that, according to the general theory of relativity, the law of the constancy of the velocity of light in vacuo, which constitutes one of the two fundamental assumptions in the special theory of relativity and to which we have already frequently referred, cannot claim any unlimited validity. A curvature of rays of light can only take place when the velocity of propagation of light varies with position. Now we might think that as a consequence of this, the special theory of relativity and with it the whole theory of relativity would be laid in the dust. But in reality this is not the case. We can only conclude that the special theory of relativity cannot claim an unlimited domain of validity; its results hold only so long as we are able to disregard the influences of gravitational fields on the phenomena (e.g. of light).
People tend to see the word velocity in the translations and tend to think vector quantity. They tend to miss the way he refers to c, which is most definitely a speed. It's pretty obvious he's talking about speed because he’s repeatedly referring to “the principle” or "one of the two fundamental assumptions". He was talking about the special relativity postulate, which is the constant speed of light. And it's even more obvious if you go back to the original German. What he actually said was "die Ausbreitungs-geschwindigkeit des Lichtes mit dem Orte variiert." I’ve got the original German version, and it translates into the speed of light varies with the locality. The word “velocity” in the translations was the common usage, as in “high velocity bullet”, not the vector quantity that combines speed and direction. He was saying the speed varies with position, hence the reference to the postulate, and hence it causes curvilinear motion. He backed it up in his 1920 Leyden Address, where he said this:
Einstein wrote:According to this theory the metrical qualities of the continuum of space-time differ in the environment of different points of space-time, and are partly conditioned by the matter existing outside of the territory under consideration. This space-time variability of the reciprocal relations of the standards of space and time, or, perhaps, the recognition of the fact that ‘empty space’ in its physical relation is neither homogeneous nor isotropic, compelling us to describe its state by ten functions (the gravitation potentials gμν), has, I think, finally disposed of the view that space is physically empty.
The thing to note here is that space is inhomogeneous, so light follows a curved path over time, hence curved spacetime. It's like a car veers when the near-side wheels encounter mud at the side of the road. It really is that simple.
