I'M standing on a hill near Towford in the Scottish Borders, in sharp autumn sunlight under a clear blue September sky. And I am, quite literally, walking in the footsteps of Agricola.

The Roman general conquered much of Britain in the first century and a stone likeness of him still overlooks the Roman ruins in Bath. But in 79 or 80AD the man himself stood where I am now, staring down at the same rich Borders farmland with an acquisitive eye – and, with a rather more wary one, up the steep slope to my left, where he knew he was being watched from the summit of the hill fort of Woden Law just 100 or so metres away. Empty and desolate today, it was occupied then by the Votadini, a Brythonic-speaking Celtic people whose capital was at Traprain Law near Edinburgh. Were they friendly? He didn't know, but he could make an educated guess.

My guide is Alistair Moffat, a 67-year-old historian, documentary-maker and author, and a keen student of both the Romans and the much fought-over region of Scotland his family have made their home for generations. He has brought me up here, through a boggy approach and up a steep track, to the six foot wide Roman road Agricola built and which can still be seen winding its way along the ridge of the hill. And so, feeling like I'm miles from anywhere, I find myself standing on Dere Street, a once well-trodden route which started at York and eventually stretched to the level of the Antonine Wall.

“I think when the Romans arrive in either 79 or 80 AD, people around here will have seen nothing like it,” Moffat says as the wind tugs at us. “An army of 10,000 legionaries and auxiliaries, with cavalry, baggage supplies and so on, ox-drawn carts and siege engines. All that kind of thing rumbling on. Of course they will have known they were coming because they had little ponies and scouts. But whoever sat on this hill here” – he sweeps his hand up to the left – “nothing would have prepared them for what was a belly-hollowing sight: the Roman Empire, coming over the hill. In force.”

There are a few walkers out today, which surprises Moffat. Normally the place is deserted, just him and the ghosts of those 10,000 legionaries. I ask him how it feels to commune with those long dead Romans, and with the souls of all the others who followed in their path, from Edward I's invading armies in the late 13th century to the thousands of Scottish drovers who used this route to take their herds to market in London well into the 19th century.

He laughs. “It sounds pretentious but the first time I came up here I brought a copy of Anthony Birley's translation of Tacitus, because I think Tacitus was with his father-in-law, Agricola, as a tribune. He doesn't write about this place or indeed the road, but he writes about the people they found and encountered. It's the first written description of Scotland, really. And he writes just brilliantly, it's as crisp a style as somebody writing yesterday. So I rather identified with him and imagined what he must have thought because when he came round this corner here on his horse, this is what he would see. We can see faint traces of wind farms and managed plantations and so on, but the shape of the ground is the same.”

But this isn't the only route Moffat has walked, just as Agricola's aren't the only footsteps he has followed and the Romans aren't the only peoples whose experiences in the Scottish landscape and in the Scottish weather he has tried to understand and feel. In his new book The Hidden Ways: Scotland's Forgotten Roads, Moffat covers around 300 miles and makes 10 journeys to all points of the compass – 10 walks along routes that in many cases were the highways of their day, in the times before cars and when hard shoulders were something you got from carrying fish over the hill to market.

That way is called The Herring Road, it runs from Dunbar to Lauder and yes, Moffat walked it. The one we're on right now is The Invasion Road. Among the other routes Moffat writes about are The Road To Heaven, a Fife pilgrim route which ran from Earlsferry to St Andrews; the High Street of Edinburgh (Moffat calls this The Road To Ruin); The Great North Road, which runs from Berwick-upon-Tweed to Cockburnspath and brought swift-riding Robert Carey to Edinburgh within hours of Queen Elizabeth I's death to proclaim James VI King of England; and the old drove road running from Broadford in Skye, across the water to Glenelg, and then to Kinlochhuorn and beyond – the territory of the Camerons, the Mackenzies and the McGregors.

The idea for The Hidden Ways was seeded around a decade ago, in a piece of historical detective work Moffat undertook while writing a book about Hadrian's Wall. Sniffing around what would have been the wall's western edge, he came across the memorial to Edward I which stands on Burgh Marsh near Carlisle. It marks the place where the so-called Hammer of the Scots died in July 1307, but it is a seriously remote spot. So what, Moffat wondered, was the 68-year-old Plantagenet king and his host doing there?

“What he was about to do is what armies had done for centuries – he was about to wade across the Solway. And the reason he was doing that is because it was much, much easier than going round the Solway Moss, which was a vast area of treacherous boggy land where the M74 runs now. It was easier, quicker – and safer – to wade across the Solway at low tide, and the marker they used on the Scottish coast was a prehistoric standing stone called the Lochmaben Stone. If you kept your eye on that, you didn't go into the deep water.”

This ancient way he calls The Wet Road and, though it's hard to prove, he thinks the Romans used it as well. Moffat has even tried it himself. A misadventure with a deep hole almost broke his leg, but until that point, he says, it was gravelly underfoot and the tide wasn't strong. Perfectly crossable, in other words.

But as well as intellectual reasons for writing the book, there were personal and political ones too.

“I'm as guilty of this as anybody – you get from A to B and who cares what's in between?” he explains. “You're checking your watch and your GPS just to get there. But our ancestors weren't like that. They walked. My mum thought nothing of walking 10 miles to a country dance and 10 miles back. We've lost our legs as a society, and having lost our legs we've lost our sensitivity to the landscape to a certain degree.”

So you could view The Hidden Way as a slow travel manifesto, a plea for people to think more deeply about their connection to the land, about their place within it, about history and about the people who have gone before. Even, perhaps, about the weather.

“It really mattered,” says Moffat. “We have all sorts of protections against the weather and it doesn't affect us as much as it used to affect people. And OK, you're wearing decent boots and waterproofs and I had a phone so I could get out of it. But you're still at the mercy of the elements and that's something you share with soldiers or pilgrims or the navvies working on the railway, or whatever. You have to deal with the conditions and they haven't changed. By and large you're still dealing with the same things: wind, rain, sun, cold. That was instructive. It's a cliché, but you learn something about yourself.”

Not all the walks Moffat undertook were along ancient routes, however. In a chapter called The Rail Road he walks the length of the Ballachulish railway line, which was cut out of the rock by gangs of labourers in the 19th century and ran from Ballachulish to Connel in Appin until its closure in 1966.

Even more modern is the Cowie Stop Line, though it's far less known and very few people have ever travelled its length.

Its story begins in 1940 with the realisation that if the German army was to invade Britain, it could well arrive in the north of Scotland. If it did, the north was undefended: there was one battalion of 800 soldiers available to defend the 400 miles of coastline running from Alness in Easter Ross to Grangemouth. The British army may have been saved at Dunkirk but its equipment had not. More than 1000 field guns were left behind, along with 600 tanks and, importantly, 850 anti-tank guns. So in place of munitions, British army planners decided they would use concrete to stop the German Panzer divisions, and that concrete would run west from Stonehaven along the line of the Cowie Water: the so-called Cowie Stop Line, “a makeshift rampart to prevent a disaster”, as Moffat calls it.

“The reality of the threat brought back all that kind of Battle of Britain drama,” he says. “We weren't fighting it up here the way they were in the south of England, with the Spitfires, but we were fighting it another way because an invasion force across the North Sea, hitting the Moray Firth with Panzer divisions and so on ... well if the Germans had captured even only a part of Scotland I think Churchill would have lost support, Viscount Halifax [then Foreign Secretary] would have become Prime Minister and we would have negotiated with Hitler.”

That drama invaded the present too. Although the Cowie Stop Line was the shortest walk Moffat undertook, it was “easily the most dangerous … it nearly killed me”. At one point, climbing a steep bank which dropped away to a gorge, he fell backwards and only saved himself by grabbing onto a branch. The accident left him muddy, wet and filthy, with the nails of one hand all torn.

Then again, the physicality required to walk long distances and the hardships that had to be endured are all part of the story. That's true of the Herring Road, which ran from Dunbar to Lauder across the Lammermuir Hills and which was travelled in large part by women carrying heavy wicker baskets filled with fresh and salted fish for market. Fresh fish had to be sold fast, which meant moving fast. Often, livelihoods depended on it. It was a hard, gruelling crossing in difficult conditions.

It's also true of one of the most evocative walks Moffat did, the one he calls The Road To Heaven. It started at Earlsferry and ran north to St Andrews, where in medieval times the town's massive cathedral was a constant draw for pilgrims visiting the shrine of St Andrew. Foot traffic was particularly heavy on the main processional feast days, when the saint's bones would be paraded through the town, but as these were in November (St Andrews Day) and February (The Feast Of The Coming Of The Relics), the journey there was often difficult.

Moffat has a personal connection to the Fife university town. He studied there, met his wife there, married there and later was elected Rector. But even so he felt the power of the place particularly strongly after the effort of getting there. Even finding the route was difficult, but when he did “it was really a joy because you ended up walking in the footsteps of people who were walking there in 1300, in 1200, who were devout Christians, believed in the power of relics and the power of St Andrew's shrine. And understanding that by walking it is much better than understanding it just by going to St Andrews or visiting the cathedral.”

Knowing that the pilgrims would have passed crosses as they entered the town, and knowing that they believed this to mean they were leaving the temporal realm and entering a holy space, allowed Moffat to better understand the tired pilgrims' mindset.

“I could see why people would do it, out of penance, desperation, simple faith,” he adds. “Out of a feeling that it was their duty as Christians to venerate a man who knew Christ. And also the old cathedral and the headland has a genius lock-eye, a really powerful sense of place.”

It all adds up to a very different way of understanding history. And besides a near death experience, sore feet, a small fortune spent on maps and the demise of his old Range Rover, there is another legacy to Moffat's 300 mile odyssey too. He plans The Hidden Ways to be the start of a long-term project to properly map the walks he made. He hopes to secure funding to make the routes safe, and to pay for wayposts and signage. He wants to be able to recruit volunteers to help with upkeep and even commission public sculpture.

And, though this is a story about old ways and lives lived in slower times, the internet has a role to play too: Moffat is planning an interactive website to which walkers will be able to upload images and videos, and an app they can download to their phone which will give them stories, information and an augmented reality soundtrack about the routes they're travelling. Moffat has already produced the Dere Street segment, written from the point of view of Tacitus and voiced by Tom Conti as “a sniffy Roman toff”.

The project is in what you might call a beta stage at the moment. But if it comes to pass then in the future you'll not only be able to walk in the footsteps of Tacitus, you'll be able to hear his voice too. Wind permitting, of course.

The Hidden Ways: Scotland's Forgotten Roads is published on October 5 (Canongate, £20)