On Lake Titicaca’s southern edge, Copacabana, Bolivia, is famed for an ancient relic, miracles and a religious rite that includes showering new cars in cold beer.

My first thoughts were that Copacabana, Bolivia, looks a lot like Italy’s Amalfi Coast. From a distance, across the dark and choppy waters of Lake Titicaca, the land had a similar, slightly arid appearance, and the hillsides boasted clusters of brightly painted houses and terracotta-hued hotels. A thin, white swath of sandy beach lined the rocky shore.

But once I ventured into the main plaza, all thoughts of Amalfi vanished.

You may also be interested in:
• Where thousands come for a miracle
• Why is Italy banning this pasta?
• The country obsessed with accordions

At Copacabana’s rough-and-tumble centre, among the worn cobblestones and bright markets, the Basilica of Our Lady of Copacabana rises stark white, save small, intricate tile work around the archways. The town is set at an incredible altitude of 3,841m, up in Bolivia’s blindingly bright-blue, thin-air skies.

“This is a very sacred place for both Bolivians and Peruvians,” Gustavo Morales, my Bolivian tour guide, told me, explaining that Copacabana is the main entry point for those travelling from Peru into Bolivia.

“Thousands of people come here every year for a blessing to Pachamama, or Mother Earth. It is said that the Virgin of Copacabana extends the life of machines and humans alike. Any time you buy any car, your first road trip must be here to Copacabana to have it blessed for safe journeys going forward. It’s a time of great celebration.”

We navigated on foot past dozens of idling cars, adorned bumper-to-fender in sprays of fresh flowers. Elderly ladies draped in vibrant aguayo (traditional woven shawls) hiked up their heavy, black skirts to climb stepladders. They placed gladiolas on car roofs while priests walked behind them, sprinkling exposed engines with holy water in plastic buckets. I could hear a lively din of toasts and conversations in both Spanish and the indigenous Andean language of Aymara.

“Many of the cars that come here are used cars,” Morales said. “But, since they are new to the person owning them, they need the blessing. The blessing is really for the people inside to have safe journeys in their new vehicle.”

Some people, he said, make the pilgrimage from La Paz, Oruro, or even as far as Santa Cruz de la Sierra or Potosí.

The blessing is really for the people inside to have safe journeys in their new vehicle

Morales explained that after the blessing, owners and locals pour beer on the cars to quench the thirst of Pachamama. I could see that in places the cobblestones were stained where the devoted had splashed their drinks.

“The priests won’t pour the beers, but sometimes if it’s a hot day, you might notice one having a sip,” he said. “The beer is really something that came about as a mark of celebration by the car owners themselves. After a car is blessed, it’s time for celebration. And, Bolivians and Peruvians both love drinking, so it’s only grown over time.”

“What’s with the rose petals?” I inquired.

“The rose petals are almost a status thing,” Morales said. “They are thrown at the cars, and the beer helps the petals stick. This way, when you drive off, everyone you pass on the way back home knows you’ve got a new car and that it’s been blessed in Copacabana.”

According to Morales, the curious car and beer blessing began sometime around the 1940s or ‘50s, when most Bolivians and Peruvians were able to afford a family car. Unable to bring boats, houses, livestock or land to the Basilica of Our Lady of Copacabana, those seeking good fortune brought the most expensive and large, yet mobile, item they owned – their cars – to this place of deep devotion.

However, the city’s rise as a place of pilgrimage began long before cars became affordable. In fact, it was considered sacred some three centuries prior to the vehicle even being invented.

“Copacabana is the area that opens the entrance to the Isla del Sol, an ancient shrine of the Incas,” said Guillermo Delgado, professor and anthropologist at the University of California at Santa Cruz and an expert on Bolivian culture. “The story starts in Copacawana – the town’s original name – where a shrine was devoted to the adoration of the Sun, considered to be the god of the Incas. Copacawana became a shrine and residence of the Acllas, the chosen women.”

When Christianity arrived from Spain in the early 16th Century, the priests were eager to convert the local Aymara inhabitants to Catholicism. They supplemented the Virgin Mary to the existing devotion to the sun and to Mother Earth.

“It’s a process that is called ‘transculturation’… a recognition of the previous cultural layer and the Christian one,” Delgado said. “They almost complement each other rather than oppose each other.”

These religions, working in tandem, helped solidify Copacabana’s growing reputation as a holy place – something that was additionally bolstered by two legends.

The first is set in the late 1500s, when an Incan tradesman named Tito Yupanqui is said to have carved a statue of the Virgin Mary, just more than 1m in height, using a particularly dark wood. Some stories proclaim that Yupanqui wasn’t even an artist, but that under guidance from the divine, he learned to sculpt specifically to bring forth this lone statue, known romantically as Morena, The Dark Virgin or the Black Madonna.

The second legend centres around Brazilian fishermen, who were said to be caught in a terrible tempest on Lake Titicaca and were saved from drowning either by the Dark Virgin statue, which led them safely to shore, or by praying to the Virgin Mary. Brazil’s famous Copacabana beach was named from this story; an homage to the sacred nature of Copacabana, Bolivia.

“Ramos Gavilán, an Augustinian priest in 1621, is known to have written about a collection of 132 ‘miracles’ that the Virgin de Copacabana realised,” Delgado said. “The Brazilian fisherman ‘miracle’ seems to have been one that was popularised, amid variants of the same story.”

Although no-one can say for sure how the statue came to be – it does exist. It inspired the construction of a small chapel specifically to house it in the 1580s. That chapel would grow over the centuries, becoming a cathedral around 1620 and eventually morphing into the current Basilica of Our Lady of Copacabana, which was fully finished in 1805. Visitors will still find the Dark Virgin statue there today.

“This statue is never to be removed from the temple,” Morales said, “because it is believed a terrible flood will happen.”

Inside Copacabana’s famous cathedral, ornate filigree curls around pillars and arches. Flowers spill from the altar and candles flicker in the dim light. At the centre of the gleaming finery, the statue stands in a small, carved niche with a mechanical base. This allows the priests to turn her so that she can face forward towards a busy Mass in the main chapel or overlook a smaller group in the more intimate chapel to the side. It is also said that, this way, she may look after both Peru and Bolivia.

Priests will bless a car any day of the week in Copacabana. However, the most popular days are Saturday and Sunday, with the most festive times being Carnival and religious holidays like Easter, as well as the Independence days for both Peru and Bolivia, which occur in late July and early August respectively.

There’s always a bit too much celebrating in Copacabana to safely drive your new car afterwards

Apart from your car, what do you need to bring, I wondered?

“It costs about 200 Bolivianos to have your car blessed… a dozen one-pint bottles of beer is what most people would buy,” Morales told me. “They would use two or three bottles on the body of the car and for spilling out to Pachamama, and then they’d drink the rest. Ideally, you arrive on a weekend and stay overnight. There’s always a bit too much celebrating in Copacabana to safely drive your new car afterwards.”

Join more than three million BBC Travel fans by liking us on Facebook, or follow us on Twitter and Instagram.

If you liked this story, sign up for the weekly bbc.com features newsletter called "If You Only Read 6 Things This Week". A handpicked selection of stories from BBC Future, Earth, Culture, Capital and Travel, delivered to your inbox every Friday.