Five years ago, British Prime Minister David Cameron looked like a modern conservative ready to offer the Republican Party a model for the future. Today, four days before critical elections here, he is a politician fighting for a second term and buffeted by many of the same problems and pressures that afflict and divide the GOP in the United States.

There are important differences between the Republican Party and Britain’s Conservative Party. There is no Christian conservative movement here, for example. So the parallels are imperfect. But the long-term prognosis for both is similar. Negative images and changing demographics combine to put both parties in a defensive posture — even as they claim some election victories along the way.

What has happened to the Conservatives over the past half-dozen years is a cautionary tale about the difficulties of rebranding a long-standing political party, lessons that are likely to play out inside the GOP over the next year as the party picks its 2016 nominee.

As Cameron’s experience has shown, striking a balance between energizing the party’s conservative base and attracting new voters through modernizing efforts is far from easy. More than stylistic shifts and cosmetic changes are needed to bring about real change against the forces of resistance. Britain is in the final days of one of the most fascinating and unpredictable elections in a generation. Neither Cameron’s Conservative Party nor the Labor Party under leader Ed Miliband appear able to command a majority of seats in the House of Commons. That would lead to a messy aftermath that could leave either party in charge but hardly in control.

Even if the Conservatives emerge from Thursday’s voting with the most seats in the House of Commons, Cameron might not be able to hold on as prime minister. If he does remain in the job, it will not erase the party’s structural problems. If anything, the campaign has highlighted them.

The Conservative Party used the intricate mechanism of a clock to illustrate the economy in a campaign video with the warning, “It’s working – don’t let them wreck it.” (YouTube/Conservatives)

Almost any outcome would remind Conservatives, the most dominant political party in Britain over the last century, of how far short they have fallen over the past 18 years. Even if they win on Thursday, this would mark the fifth consecutive election in which they have failed to capture a majority of seats, and they haven’t won more than 36 percent of the national vote since 1992.

Labor, too, has its problems, owing to voters’ qualms about its fiscal stewardship and the sudden and remarkable collapse of the party in Scotland, long a Labor stronghold. But even some supporters of Cameron acknowledge that there now may be a more natural popular majority in the United Kingdom for the ideas and policies of Labor than for the Conservatives.

It wasn’t meant to be this way. Cameron assumed the leadership of his party a decade ago on a pledge to rebrand the Tories, much the same way former prime minister Tony Blair had changed the Labor Party in the 1990s.

“With Cameron and [George] Osborne [now chancellor of the exchequer], we took the view that the Conservative Party had to modernize,” Steve Hilton, who was a Cameron adviser at the time, said in a recent interview. “That felt like a moment of change.”

The thinking was to apply conservative principles to a new set of problems, to express traditional views in a more modern way. Cameron embraced the issue of climate change through the principle of conservation. He announced his support for same-sex marriage in the context of stable relationships and strong families. He talked in the 2010 campaign about using government and the private sector to create a “Big Society” as a way to signal compassion and empathy.

Those efforts at reform were pushed back by a series of forces. One was the rise of the United Kingdom Independence Party (UKIP), whose nationalist, anti-immigration, anti-Europe message drained aggrieved voters away from the Conservatives. Determined to win back some of those defectors, the Tories moved their message to the right — at a cost of alienating some of the voters they were trying to attract with the kinder and gentler appeal.

The other obstacle turned out to be the economic problems and big budget deficits Cameron inherited from the last Labor government. Those realities necessitated austere fiscal policies that prevented more spending on some programs for the middle class, giving the party image a hard edge. The economy has improved, but as in the United States, the unequal distribution of those gains has left many feeling left out and looking for someone to blame.

Polls show that more voters trust the Conservatives over Labor on the economy generally but don’t think the Tories are on their side. Peter Kellner, president of the polling firm YouGov, said of the Conservatives: “They have not shifted their brand from an out-of-touch party of the rich. The Tories have to persuade people they are determined to make the lives of ordinary people better . . . not unlike the Republicans.”

In some ways, the Republicans have gone through similar storms. The tea party has been to Republicans what UKIP has been to the Conservatives — a powerful up-from-the-people movement that has pushed each to the right and complicated the efforts of reformers to be heard. Meanwhile, President Obama successfully portrayed the GOP under Mitt Romney as out of touch and insensitive to working families.

But if Cameron and his party felt the need to change after three consecutive defeats in national elections, the pressure for reform of the Republican Party has ebbed and flowed with the election results. With each presidential election defeat, Republicans have rebounded with big midterm victories — even if their long-term problems remain.

For any Republicans looking to reshape the party’s image ahead of the 2016 general election — think Jeb Bush — Cameron’s experience is instructive. Andrew Cooper, a former director of strategy for Cameron who is now with the strategic advising firm Populus, said Blair was successful in part because he and his allies fully agreed with the public’s criticism of their party.

“Cameron and Osborne didn’t. . . . They understood we needed to seek to be a different party, but it didn’t really go very deep,” he said.

The other parallel between the fortunes and futures of the Conservatives and the Republicans is the implication of changing demographics, which will require both to change. Although not yet as widespread as in the United States, the changing face of Britain presents a challenge to a Conservative Party that is heavily dependent on voters who are older and white.

Cooper said he tells fellow Conservatives that, as badly as Romney performed among nonwhite Americans, the Conservatives did worse with nonwhite voters in 2010. “The only reason it didn’t kill us then is because we’re not quite at the demographic evolution,” he said. “But Britain is changing incredibly rapidly. We’ve got to address that.”

All successful parties change to adapt to changing times, no matter their ideology, and defeat is a powerful motivator. But those who think the process of renewal is a matter of drawing up fresh talking points and clever photo ops should look at what has happened here for a reality check.