People engage in moral talk all the time. When they make moral claims in public, one common response is to dismiss them as virtue signallers. Twitter is full of these accusations: the actress Jameela Jamil is a ‘pathetic virtue-signalling twerp’, according to the journalist Piers Morgan; climate activists are virtue signallers, according to the conservative Manhattan Institute for Policy Research; vegetarianism is virtue signalling, according to the author Bjorn Lomborg (as these examples illustrate, the accusation seems more common from the Right than the Left).

Accusing someone of virtue signalling is to accuse them of a kind of hypocrisy. The accused person claims to be deeply concerned about some moral issue but their main concern is – so the argument goes – with themselves. They’re not really concerned with changing minds, let alone with changing the world, but with displaying themselves in the best light possible. As the journalist James Bartholomew (who claimed in 2015 to have invented the phrase, but didn’t) puts it in The Spectator, virtue signalling is driven by ‘vanity and self-aggrandisement’, not concern with others.

Ironically, accusing others of virtue signalling might itself constitute virtue signalling – just signalling to a different audience. Whether it should be counted as virtue signalling or not, the accusation does exactly what it accuses others of: it moves the focus from the target of the moral claim to the person making it. It can therefore be used to avoid addressing the moral claim made.

Here, though, I want to consider a different issue. In the only full treatment of the topic in the academic literature (that I know of), the philosophers Justin Tosi and Brandon Warmke accuse the ‘moral grandstander’ (their term for the virtue signaller) of perverting the function of public moral discourse. According to them, ‘the core, primary function that justifies the practice’ of such public moral discourse is ‘to improve people’s moral beliefs, or to spur moral improvement in the world’. Public moral talk aims to get others to see a moral problem they hadn’t noticed before, and/or to do something about it. But, instead, virtue signallers display themselves, taking the focus away from the moral problem. Since we often spot virtue signalling for what it is, the effect is to cause cynicism in the audience, rather than to induce them to think the signaller is so great. As a result, virtue signalling ‘cheapens’ moral discourse.

But Tosi and Warmke offer no evidence for their claim that the primary, or the justifying, function of moral discourse is improvement in other people’s beliefs or in the world. That’s certainly a function of moral discourse, but it’s not the only one (as they recognise).

Perhaps, in fact, virtue signalling, or something like it, is a core function of moral discourse.

Signalling is very common in nature. The peacock’s tail, for instance, is a signal of evolutionary fitness. It’s what biologists call an honest signal, because it’s hard to fake. It takes a lot of resources to build a tail like that, and the better the signal – the bigger and brighter the tail – the more resources must have been devoted to it. Stotting – a behaviour seen in some animals, involving leaping straight up in the air, with all legs held stiffly – is probably also an honest signal of fitness. The gazelle who stotts vigorously demonstrates to potential predators that it’s going to be hard work to run it down, which might lead the predators to look for easier prey. Humans also engage in signalling: wearing an expensive suit and a Rolex watch is a hard-to-fake signal of wealth and might help to communicate that you’re a suitable trading partner or a desirable mate.

In the cognitive science of religion, it is common to identify two kinds of signals. There are costly signals and credibility-enhancing displays. The peacock’s tail is a costly signal: it takes a lot of energy to build it and drag it around, and it gets in the way when fleeing predators. Credibility-enhancing displays are behaviours that would be costly if they weren’t honest: for example, the animal who ignores a nearby intruder not only communicates to group members its belief that the intruder isn’t dangerous, but does so in a way that certifies the sincerity of the communication because, if the intruder was dangerous, the signalling animal itself would be at risk.

Lots of religious behaviour can be understood as costly and credibility-enhancing signalling. Religions mandate many behaviours that are costly: fasting, tithing, abstinence from sex except in certain contexts, and so on. All of these behaviours are costly not only in everyday terms, but also in evolutionary terms: they reduce opportunities for reproduction, resources for offspring, and so on. Religious activities are also credibility-enhancing displays of religious belief: no one would pay these costs unless they really believed that there was a payoff.

Why, from an evolutionary point of view, would someone signal religious commitment? A likely explanation is that the function is to secure the benefits of cooperation. Cooperation with others is often a risky activity: there is the constant possibility that the other person will free-ride or cheat, making off with the benefits without paying the costs. The more complex the social group, and the easier it is to move between groups, the higher the risks: whereas in small groups we can keep track of who is honest and reliable, in a large group or when interacting with strangers, we can’t rely on reputation.

Signalling helps to overcome the problem. The religious person signals her commitment to a code, at least of cooperating with the ingroup. She signals her virtue. Her signal is, by and large, an honest signal. It is hard to fake, and religious groups can keep track of the reputation of their members if not of everyone else, since the pool is so much smaller. This kind of explanation has been invoked to explain the prominence of Quaker business people in the early years of the industrial revolution. These Quakers trusted one another, in part because involvement with the Society of Friends was an honest signal of willingness to abide by codes of ethics.

Religious signalling is already moral signalling. It is hardly surprising that, as societies secularise, more secular moral claims come to play the same role. Virtue signalling is supposed to be signalling to the ingroup: it shows that we are, by their lights, ‘respectable’ (in Tosi and Warmke’s word). That’s not a perversion of the function of morality; it is moral discourse playing one of its central roles.

If such virtue signalling is a central – and justifying – function of public moral discourse, then the claim that it perverts this discourse is false. What about the hypocrisy claim?

The accusation that virtue signalling is hypocritical might be cashed out in two different ways. We might mean that virtue signallers are really concerned with displaying themselves in the best light – and not with climate change, animal welfare or what have you. That is, we might question their motives. In their recent paper, the management scholars Jillian Jordan and David Rand asked if people would virtue signal when no one was watching. They found that their participants’ responses were sensitive to opportunities for signalling: after a moral violation was committed, the reported degree of moral outrage was reduced when the participants had better opportunities to signal virtue. But the entire experiment was anonymous, so no one could link moral outrage to specific individuals. This suggests that, while virtue signalling is part (but only part) of the explanation for why we feel certain emotions, we nevertheless genuinely feel them, and we don’t express them just because we’re virtue signalling.

The second way of cashing out the hypocrisy accusation is the thought that virtue signallers might actually lack the virtue that they try to display. Dishonest signalling is also widespread in evolution. For instance, some animals mimic the honest signal that others give of being poisonous or venomous – hoverflies that imitate wasps, for example. It’s likely that some human virtue signallers are engaged in dishonest mimicry too. But dishonest signalling is worth engaging in only when there are sufficiently many honest signallers for it make sense to take such signals into account. While some virtue signallers might be hypocritical, the majority probably are not. So on the whole, virtue signalling has its place in moral discourse, and we shouldn’t be so ready to denigrate it.