This paper studies the effect of market distortions in the manufacturing sector in Morocco. Recent microdata are used to calculate the extent of resource misallocation associated to these distortions and the potential total factor productivity (TFP) gain resulting from their removal. Market distortions in the manufacturing sector in Morocco are higher compared with developed countries and slightly more important compared with other developing countries, such as China and India. These distortions decreased between 2007 and 2013. Full liberalization would raise TFP by about 84 percent. If distortions are removed to the level of selected developed countries with better resource allocation, the increase in TFP would be of 56 percent. The paper also finds that industries that are more opened to competition (international and domestic) such as machinery and textiles industries present lower levels of market distortions compared with more protected industries with relatively little competition, such as the food industry. Besides, a higher level of TFP can be achieved if more resources are allocated to “young” and “small” firms. The main results of the paper are robust to an alternative estimation that uses a different methodological framework with a less extensive theoretical framework. The paper discusses policies to further limit the extent of product and factor market distortions in Morocco.