Scientists have taken a big step forward in clock technology that will help them more accurately measure both space and time.

A team developed the first portable version of an optical clock, which is more stable and exact than the standard atomic clock, and put it to test on a mountain, according to a study in the journal Nature Physics. In addition to attaining a more exact measurement of time while on the go, comparing the time on the high-altitude clock with one on the ground gave the researchers a better measurement of the distance up the mountain that they had traveled.

At the heart of the experiment is Albert Einstein’s famous theory of relativity, which dictates that time progresses at varying rates based on someone’s position in a gravitational field. Although the change is subtle, that includes Earth — at different altitudes, people will experience time differently because of the change in gravitational force as one moves away from the center of the planet.

That means a highly accurate clock operating on a mountaintop will measure time as moving slightly more quickly than a highly accurate clock operating at sea level.

In the case of this experiment, the sea-level clock was in Torino, Italy, and the portable optical clock was at the French Modane Underground Laboratory, located in a road tunnel called Fréjus that connects France and Italy in the Alps. The altitude difference between the two places is about 1,000 meters.

“With improvements to the accuracy of the transportable optical clock, this technique has the potential to resolve height differences as small as 1 cm across the Earth’s surface,” the National Metrology Institute of Germany explained about the research. “This novel method could lead to higher resolution measurements of the Earth’s gravity potential, allowing scientists to monitor, with unprecedented accuracy, continental height changes related to sea levels and the dynamics of ocean currents. It will also lead to more consistent national height systems.”

Atomic clocks use the tiny movements of atoms to measure time, like a miniature version of the pendulum in the tower of a grandfather clock. An optical atomic clock is also called an optical lattice clock because it uses a lattice of laser beams to trap atoms — in the case of this clock, strontium — and make the measurement of their movements more precise.

“Our proof-of-principle experiment demonstrates that optical clocks could provide a way to eliminate discrepancies and harmonize measurements made across national borders,” researcher Helen Margolis said in the institute’s statement. “One day such technology could help to monitor sea level changes resulting from climate change.”

The team is working on refining their design for the portable optical clock.

“Optical clocks could help to establish a unified world height reference system with significant impact on geodynamic and climate research,” researcher Heiner Denker said in the statement.