The theory of comparative advantage, first developed by English economist David Ricardo in 1817, is a theory about the potential gains from trade for companies, countries or people that arise on account of differences in factor endowments or technological progress.