Digitalization of the economy is impossible without a corresponding legal transformation. It consists in adapting existing regulatory legal acts to the changed realities of economic activity and adopting new ones regulating public relations regarding previously unknown phenomena. The Japanese legislator consistently solves such problems. In terms of the main aspects of the legal regulation of ecommerce, Japan occupies a leading position in the world. The article analyzes the modern Japanese legislation on ecommerce and assesses the trends of its development. Special attention is paid to the legal regulation of digital ecommerce platforms.