Four years after they first went on an expedition deep into the jungle of Brazil's Javari Valley, Dom Phillips and Bruno Pereira teamed up again, each working on a big new project to save the Amazon. It cost them their lives.

The British journalist and Brazilian Indigenous expert, both at a crossroads in life, had gravitated back to the far-flung region they visited together in 2018, home to an Indigenous reservation bigger than Austria.

On their 2018 trip, Pereira, then head of Brazilian Indigenous agency FUNAI's program for isolated tribes, invited Phillips, then on assignment for The Guardian, to cover a grueling 17-day expedition into the thick of the rainforest.

Searchers look for the bodies of Pereira and  Phillips would be buried after a suspect indicated the location, in Atalaia do Norte, Amazonas state, Brazil, on June 15, 2022
Searchers look for the bodies of Pereira and Phillips would be buried after a suspect indicated the location, in Atalaia do Norte, Amazonas state, Brazil, on June 15, 2022 AFP / Joao Laet

The goal was to survey the lands occupied by an uncontacted tribe, to try to avoid conflicts with other ethnicities.

In his article, Phillips wrote admiringly of Pereira squatting by a campfire in flip-flops, eating a monkey's brain for breakfast as he discussed policy.

A bromance had clearly been born.

An indigenous man takes part in a protest outside the Ministry of Justice in Brasilia, during the search for missing British journalist Dom Phillips and Brazilian Indigenous affairs specialist Bruno Pereira on June 14, 2022
An indigenous man takes part in a protest outside the Ministry of Justice in Brasilia, during the search for missing British journalist Dom Phillips and Brazilian Indigenous affairs specialist Bruno Pereira on June 14, 2022 AFP / EVARISTO SA

Four years later, the duo was back in the Javari Valley, in northwestern Brazil near the Peruvian and Colombian borders.

Phillips, 57, had set aside newspaper reporting to write a book on the world's biggest rainforest.

Pereira, 41, had taken leave from FUNAI and set up a program to help Indigenous people detect and report invasions of their land by illegal loggers, miners and poachers.

On June 2, they set off by boat from Atalaia do Norte, a sleepy town at the juncture of the Itaquai and Javari rivers, so Pereira could show Phillips his project.

Map of Brazil locating Javari Valley where a British journalist and Brazilian indigenous expert went missing on June 5.
Map of Brazil locating Javari Valley where a British journalist and Brazilian indigenous expert went missing on June 5. AFP / Patricio ARANA

They planned to return on June 5. They never arrived.

Police say as the pair motored back to town that Sunday in a small boat, illegal fishermen sped up and shot them, then buried them in the forest.

Friends and relatives of journalist Dom Philipps and indigenous expert Bruno Pereira protest in Copacabana beach, in Rio de Janeiro, Brazil on June 12, 2022
Friends and relatives of journalist Dom Philipps and indigenous expert Bruno Pereira protest in Copacabana beach, in Rio de Janeiro, Brazil on June 12, 2022 AFP / CARL DE SOUZA

Pereira, who took leave from FUNAI after clashing with the program-cutting leadership appointed when far-right President Jair Bolsonaro took office in 2019, found a new home at an Indigenous-rights group, UNIVAJA.

There, he trained Indigenous volunteers to patrol the Javari Valley, entering incursions into a specially created app.

The reservation has seen a surge of land invasions, threatening it at a time when numerous studies have found that native people's stewardship of their lands is key to protecting the Amazon, a vital resource in the race to curb climate change.

Guarani indigenous people and environmental activists protest in the wake of the killing of British journalist Dom Phillips and his guide Bruno Pereira in Sao Paulo, Brazil, on June 18, 2022
Guarani indigenous people and environmental activists protest in the wake of the killing of British journalist Dom Phillips and his guide Bruno Pereira in Sao Paulo, Brazil, on June 18, 2022 AFP / NELSON ALMEIDA

The project earned Pereira death threats.

"With the app, they had the whole crime scene mapped out, and they were preparing a report to show the authorities," said Brazilian-American journalist Monica Yanakiew of Al Jazeera English, who accompanied Pereira on a similar trip in December.

"Everybody says you can't patrol an area that large without a whole army, but if you have 10 Indigenous patrollers who know the lay of the land and an app, you can figure out what's going on," she told AFP.

It was this blend of masterful organizing and intimate knowledge of the terrain that made Pereira "one of the great Indigenous experts," said a long-time friend, veteran Brazilian reporter Rubens Valente.

"He had a very rare gift. He was someone you just knew would go on to big things -- environment minister or something. His death is a tremendous loss."

Phillips, one of the most respected foreign correspondents covering Brazil, had put that job on hold last year when he won a prestigious Alicia Patterson fellowship for his book project.

A deeply researched dive into the Amazon and the people who live here, the book was meant to be a highly readable look at practical ways to protect the rainforest.

His working title was "How to Save the Amazon."

"He was so excited," said Jenny Barchfield, a friend who met Phillips when they were both foreign correspondents in Rio de Janeiro in the 2010s.

She remembered him as friendly, kind, voraciously curious and "magnetic," with bright blue eyes and an impish grin.

"He talked about how exciting it was to be able to think beyond the next story to this long project that had really important ramifications," she said.

"The topic he was writing on literally could not be more important for everybody and everything on Earth."

Friends say Phillips was well into writing the book. They are exploring ways to finish it and get it published.

"I'm sure Dom would want you to take some positives out of the tragedy," said another friend, Scottish former foreign correspondent Andrew Downie.

"If there is a positive point to be taken out of this, it might be that people are looking at the Amazon now."