PARIS, July 22 -- Every autumn, roughly five million French children under 15 return to school carrying the social media habits they have built across the preceding year. By the time this school year begins, they will be locked out. France's parliament completed a vote on Tuesday making the country the first in the European Union to formally prohibit minors under 15 from accessing social media, a law that transforms what had been a political pledge from President Emmanuel Macron into a binding legal obligation for the world's largest technology platforms.

The legislation requires TikTok, Instagram, Snapchat, Facebook, and any other platform operating in France to verify the ages of users at registration and block those who cannot confirm...