The rule of law is not just a necessary condition for a modern liberal society but also an important prerequisite for a stable, effective and sustainable market economy. However, relevant legal norms may be more or less successful depending on their social reception within a particular country. This study explores the connection between the rule of law, especially in terms of how it is viewed socially, and the functioning of market economy in the examples of two geographically contiguous yet often-diverging countries, namely Germany and Poland. We utilise two approaches to examine this issue, first studying societal perceptions of the various dimensions of the rule of law by way of standardized surveys and in-depth interviews conducted in both countries to determine the de facto state of the rule of law in the economic context. Secondly, we measure the effect of the de jure and de facto rule of law on economic outcomes using a multivariate panel analysis. Combining new institutional economics and sociology of law, our analysis finds that Polish firms perceive the rule of law and its execution by the state in a restrictive perspective, contributing to insecurity. German interviewees, however, showcase the supportive and transaction cost-reducing properties of the rule of law, displaying higher trust in the state. These findings are supported by an econometric analysis of the drivers of rule of law in both Poland and Germany, which shows the importance of rule of law in terms of a level playing field contributing to higher levels of investment.