More than one million dogs in the UK have not yet been microchipped - one in eight of the estimated canine population - the Department for Environment, Food and Rural Affairs (Defra) said.
From today, dog owners must make sure their pet is fitted with a microchip by the time it is eight weeks old, or face a fine of up to £500.
If local authorities come across a dog without a microchip, owners will have up to 21 days to comply with the law.
Defra’s Animal Welfare Minister George Eustice said: “We are a nation of dog lovers and we want to make sure they stay safe.
“Microchipping our dogs will not only reunite people with their lost or stolen pets, but also help to tackle the growing problem of strays roaming the streets, and relieve the burden placed on animal charities and local authorities.
“Microchipping is vital for good dog welfare and a simple solution for responsible pet owners to provide peace of mind and ensure your much-loved dog can be traced.”
When a dog is microchipped a tiny chip about the size of a grain of rice is inserted under the loose skin on the back of its neck, giving it a unique 15-digit code.
If a dog becomes lost or gets stolen and is picked up by a local authority or a shelter, the microchip can be scanned and matched to contact details stored on a database.
Owners must make sure the microchip is updated if their contact details change, and people should ask for proof a microchip has been fitted before buying a new pet.
Microchipping technology has been in place for around a quarter of a century and is now compulsory in England, Wales and Scotland.
The new law does not replace previous requirements for dogs to wear a collar and tag with their owner’s name and address when in a public place, Defra said.
More than a quarter of lost dogs (28%) were reunited with their owners in 2015 thanks to microchipping, the Dogs Trust said.
Countries such as Northern Ireland, which already have compulsory microchipping, have seen a decrease in the number of stray, lost and abandoned dogs, Defra said.
Around 120,000 stray dogs are kept in council and charity kennels, the Government department estimated.
Councillor Simon Blackburn, chair of the Local Government Association (LGA)’s Safer and Stronger Communities Board, said the new law would free up public money spent looking after strays.
He said: “Councils will of course take a proportionate approach to enforcing the new law, but owners can help by ensuring they get their dogs chipped as soon as possible.
“The new microchipping law will improve animal welfare by helping councils return even more stray dogs to their owners while reducing the huge cost to the public purse and the number of owners paying mounting fees for unplanned stays in kennels.”