The year 2015 will have an extra second — which could wreak havoc on the infrastructure powering the internet.

At 11.59 on June 30, clocks will count up all the way to 60 seconds. That will allow the Earth’s spin to catch up with atomic time.

The Earth’s spin is gradually slowing down, by about two thousandths of a second per day, but atomic clocks are constant. That means that occasionally years have to be lengthened slightly, to allow the slowing Earth to catch up with the constant clock.

But last time it happened, in 2012, it took down much of the internet. Reddit, Foursquare, Yelp and LinkedIn all reported problems, and so did the Linux operating system and programmes using Java.

The reset has happened 25 times since they were introduced in 1972, but the computer problems are getting more serious as increasing numbers of computers sync up with atomic clocks. Those computers and servers are then shown the same second twice in a row — throwing them into a panic.

If a computer is told to do an operation at the time that is repeated, for instance, the computer is unsure what to do. Or if an email is received in that moment, it could find its way in the wrong bit of the server.

Last time, Google anticipated the problem and built a smart update, which it called “leap smear”. It modified its servers so that they would add a little bit of extra time every time they were updated, so that by the time of the leap second they were already caught up with the new time. It said when it laid out the plan in 2011 that it would use the same technique in the future, when new leap seconds are announced.

Leap seconds were initially added at least once a year, but have slowed since 1979. The US wants to get rid of them entirely, arguing that they cause too much disruption, but others have opposed the change.