Did Einstein know about the Michelson-Morley experiment? The second postulate of special relativity deals with constancy of light in inertial reference frames. But, how did Einstein come to this conclusion? Did he know about the Michelson-Morley experiment? 
 A: Yes, Einstein was aware of the Michelson-Morley experiment.
The Michelson-Morley experiment looked for an absolutely stationary space the Earth moves through. The near-null result is evidence the aether is not an absolutely stationary space.
"The word 'ether' has extremely negative connotations in theoretical physics because of its past association with opposition to relativity. This is unfortunate because, stripped of these connotations, it rather nicely captures the way most physicists actually think about the vacuum. . . . Relativity actually says nothing about the existence or nonexistence of matter pervading the universe, only that any such matter must have relativistic symmetry. [..] It turns out that such matter exists. About the time relativity was becoming accepted, studies of radioactivity began showing that the empty vacuum of space had spectroscopic structure similar to that of ordinary quantum solids and fluids. Subsequent studies with large particle accelerators have now led us to understand that space is more like a piece of window glass than ideal Newtonian emptiness. It is filled with 'stuff' that is normally transparent but can be made visible by hitting it sufficiently hard to knock out a part. The modern concept of the vacuum of space, confirmed every day by experiment, is a relativistic ether. But we do not call it this because it is taboo." - Robert B. Laughlin, Nobel Laureate in Physics, endowed chair in physics, Stanford University
"any particle, even isolated, has to be imagined as in continuous “energetic contact” with a hidden medium ... If a hidden sub-quantum medium is assumed, knowledge of its nature would seem desirable. It certainly is of quite complex character. It could not serve as a universal reference medium, as this would be contrary to relativity theory." - Louis de Broglie, Nobel Laureate in Physics
"According to the general theory of relativity space without ether is unthinkable; for in such space there not only would be no propagation of light, but also no possibility of existence for standards of space and time (measuring-rods and clocks), nor therefore any space-time intervals in the physical sense." - Albert Einstein, Nobel Laureate in Physics
http://www-groups.dcs.st-and.ac.uk/~history/Extras/Einstein_ether.html
"Think of waves on the surface of water. Here we can describe two entirely different things. Either we may observe how the undulatory surface forming the boundary between water and air alters in the course of time; or else-with the help of small floats, for instance - we can observe how the position of the separate particles of water alters in the course of time. If the existence of such floats for tracking the motion of the particles of a fluid were a fundamental impossibility in physics - if, in fact nothing else whatever were observable than the shape of the space occupied by the water as it varies in time, we should have no ground for the assumption that water consists of movable particles. But all the same we could characterise it as a medium."
"More careful reflection teaches us however, that the special theory of relativity does not compel us to deny ether." - Albert Einstein
A: 
Did he knew about the Michelson-Morley experiment?  

He just knew the name of the experiment not any details. The experiment didn't play any role in the formulation of STR by Albert Einstein.
The context is taken from the book:
Special Theory of Relativity 
by V. A.; Atanov, Yuri (Trans.) Ugarov (Author) 
Art: Was Michelson's experiment "decisive" for the creation οΙ 
the special theory οΙ relativity? 
An article by R. Shankland, 
published in 1963, the following excerpt from his interview with 
Einstein dating back to 1950: 

"When Ι asked him how he had learned of the Michelson Morley experiment, he told me that he had become aware of it through 
  writings of Η. Α. Lοrentz, but only after 1905 had it come to his 
  attention! "Otherwise" he said, "I would have mentioned it in my 
  paper!" indeed, Einstein's 1905 paper contains no mention of Μichelson's experiment or references to Lorentz's papers."

A letter written by Albert Einstein: 

"Ιn my own development Michelson's result had not had a considerable influence. Ι even do not remember if Ι knew of it at all when I wrote my first paper on the subject (1905). Τhe explanation is that Ι was, for general reasons, firmly convinced how this could be reconciled with our knowledge οf electro-dynamics. One can therefore understand why in my personal struggle Michelson's 
  experiment played no role or at least no decisive role..." 

A: Yes, Einstein knew about the Michelson-Morley experiment. Toward the end of his life, he saw it as increasingly important for relativity theory.
Here's an excerpt from


*

*Clark, Ronald. 1971. Einstein: life and times. New York: World Pub.
Co. p. 78:



As Einstein said years later, talking to Sir Herbert Samuel in the grounds of Government House, Jerusalem: "If Michelson-Morley is wrong, then relativity is wrong."



A: Einstein certainly knew about (and appreciated) the Michaelson-Morley experiment later in life, as the other answers demonstrate, but the historical record is unclear as to whether he knew about it when he developed special relativity in 1905. He himself was quite inconsistent on the subject: http://adsabs.harvard.edu/full/1974Obs....94...81J.
