Introduction

The term “sentience” refers to having feelings, and pain is often assumed to be the most basic aspect, or at least the most important in terms of animal welfare (Walters 2018; Passantino et al. 2021). However, animal sentience has been described in broader terms, such as the (1) ability to evaluate the actions of others in relation to itself and third parties, (2) to remember some of its own actions and their consequences, (3) to assess risks and benefits, (4) to have some feelings, and (5) to have some degree of awareness (Broom 2007). These features imply cognitive abilities, so the animal can acquire, process, store, and act on information (Shettleworth 1998). The term “consciousness” has been defined as states of sentience or awareness (Searle 1993) and seems to be like Broom’s definition of sentience. Others, however, suggest sentience and consciousness differ (Dawkins 2012; Godfrey-Smith 2020). However, like Braithwaite (2010), I will not attempt to distinguish between these two terms, but neither do I suggest they are the same. Rather, I will focus on the cognitive abilities used by hermit crabs in relation to their use of shells. Hermits are excellent subjects for this, because they show distinctive activities by which they gather information. These activities can be observed and subject to experimental manipulation in order gain insights into what, when and how the crabs gather and use information. They have also been studied with respect to their ability to experience pain. Hopefully, the review will illustrate the current state of knowledge about perceptual and information-gathering abilities in hermit crabs, as well as their ability to make complex decisions. A key aim, however, is to consider if those abilities might indicate some form of awareness and feelings, and hence sentience (Broom 2007).

Hermit crabs comprise the superfamily Paguroidea within the order Decapoda, subphylum Crustacea, phylum Arthropoda. They are primarily marine, but some species live on land after their larval stage, and almost all species inhabit empty gastropod shells (Elwood and Neil 1992). This use of shells offers advantages to the crabs in terms of protection from predators (Arce and Alcaraz 2013; Arce and Córdoba-Aguilar 2018), other hermit crabs (Elwood and Neil 1992), strong water flow (Alcaraz et al. 2020), desiccation (for terrestrial species) (Elwood and Neil 1992), and females protect their developing eggs/embryos by fixing them to abdominal appendages, which remain within the shell (Elwood et al. 1995). Furthermore, hermit crabs do not require calcification of the abdomen for protection, because that is provided by the gastropod shell. Of course, there are costs to this behaviour, not least the energy required to carry the shell as the crab moves (Herreid and Full 1986; Briffa and Elwood 2005a). In addition, as a crab grows, it will incur costs when they seek and secure larger shells so that the crab can maintain the protective benefits of being able to fully withdraw.

Shells are a limiting resource (Fotheringham 1976; Scully 1979), and many hermits occupy shells that are a poor fit, of a less preferred species, damaged, either with bits broken from the shell or with holes drilled into the shell by predators of the original mollusc (Pechenik and Lewis 2000), or too heavy because of epibionts (Briffa and Elwood 2005a). Furthermore, even if a crab’s shell appears to be sound and a reasonable fit, there might be gains in fitness by obtaining another shell with a better shape or not as heavy. Thus, hermit crabs are inquisitive about shells (Godfrey-Smith 2020). There are four main situations in which a crab might obtain a new shell. First, a crab in a shell might encounter an empty shell, and hermits readily approach and investigate shells. This involves information gathering from various sources to determine if the new shell is superior to the original. I also consider how the environment might affect the utility of shells, and if crabs alter their choices to meet specific, transient needs. Second, a housed crab might encounter another housed crab and engage in a contest for the opponent’s shell. In this case the evaluations appear to be of the opponent’s shell compared to the current shell, plus other assessments of the opponent and itself, and the progress of the contest. Assessment activities involved in fighting thus appear to be more complex compared with the assessment of a vacant shell. Third, the crab might have abandoned its shell and thus be naked. Such naked crabs are highly vulnerable to predation and tend to take any shell with minimal evaluation, and so provide few insights into cognitive processes. Of more interest, however, are the decisions to abandon shells. I examine shell abandonment should the shell become stuck, if something aversive occurs within the shell or when the crab is attacked by another crab. Finally, I consider how terrestrial hermit crabs wait to take part in social interactions by which a vacancy chain forms that allows resources to be passed from one crab to another, so each participant might gain in shell quality.

Encounters by housed crabs with empty shells

Hermit crabs perceive shells from a distance, primarily by vision, and the colour and contrast of shells influence whether the crab will approach (Fig. 1a) (Reese 1963; Briffa et al. 2008a, b; Rimmer et al. 2021). Crabs might also be influenced by chemical cues from the shell (Lancaster 1988; Chiussi et al. 2001). As crabs approach a shell, they may touch it with their walking legs, and move their antennae over the shell surface. They may take hold of the shell with their chelipeds (clawed appendages) and move the chelipeds and walking legs over the exterior (Fig. 1b). The shell is turned so the crab can access the aperture, and the chelipeds, and perhaps a walking leg, are inserted into the aperture and moved around the interior (Fig. 1c). The exterior might then be examined again and sometimes the interior is re-examined (Reese 1963; Elwood and Stewart 1985) and the crab may switch several times between these two activities. The empty shell may be abandoned at any point. Alternatively, the hermit crab will move to the new shell (Fig. 1d) (Elwood and Neil 1992).

Fig. 1
figure 1

a Crab (Pagurus bernhardus) in a less preferred species of shell (Gibbula) approaches and visually assesses an empty shell of a preferred species (Littorina). b Crab runs its chelipeds over the exterior of the shell. c Shell is turned so the chelipeds can be inserted into the aperture. d Crab releases the abdominal grip on the Gibbula shell and swings the abdomen into the new Littorina shell. (A and D Photos by R W Elwood reprinted with permission from Elwood and Neil 1992) (B and C Photo by R W Elwood)

The process does not end at this point, because the crab may withdraw deeply into the new shell and repeatedly come partially forward and then back again within the shell (Fig. 2a). It might partially emerge and then move its walking legs backwards so they can feel over the exterior of the new shell (Fig. 2b). It might also lift the new shell and hold it up off the substrate (Fig. 2c). While performing these activities the crab stays near to the old shell and often keeps hold of it with a cheliped (Reese 1963; Elwood and Stewart 1985; Elwood and Neil 1992).

Fig. 2
figure 2

a Crab repeatedly withdraws into the new shell in a swift and apparently forceful manner. b Crab moves the walking legs backwards and runs them over the surface of the new shell. c Crab balances on its chelipeds and walking legs and holds the new shell off the substrate. d Crab then turns its attention to its old shell, which it investigates before making a final choice. (Photos by R W Elwood reprinted with permission from Elwood and Neil 1992)

The crab might accept the new shell and move away but often the crab stays and investigates the exterior (Fig. 2d) and interior of the old shell, in much the same way as when it first investigated the new shell. The crab may stop the sequence at that point and walk away in the new shell, but sometimes the crab will move back to the original shell and move away in that. However, the crab might start the entire investigatory sequence again before making a final decision about which shell to occupy.

Here I examine the processes involved in gathering information about different features of each shell that lead to the final choice. I ask what information is gathered, when it is gathered and how quickly each stage takes, while the crab determines which is the better shell for that crab at that time. I consider developmental changes in the ability to assess the suitability of the shell from movements of the chelipeds when investigating the interior of the shell. I ask how the crab integrates the various sources of information, gained from using different body parts and different actions towards one shell and compare those with information about the alternative shell, possibly gained from similar actions at different times or, indeed, different actions at different times. I consider the role of memory of information gained at one point in how that affects the assessment at later stages. Finally, I ask if memory of the overall shell quality is compared with memory of the overall quality of the alternative shell so that the crab may select the better shell.

Information gathered during shell investigation

Decisions by hermit crabs about approaching and investigating empty shells have been shown to be influenced by the quality of the shell they occupy. Crabs were more likely to approach and contact an empty shell if they were currently in a shell that was too small (Elwood and Stewart 1985). Furthermore, crabs that were approaching but had not yet contacted the empty shell showed shorter startle responses to a moving shadow (withdrawing into the shell) if they were in a shell of 50% of optimum weight, compared to those in a better shell of 75% of optimum weight (Fig. 3). Thus, crabs have information about their current shell, presumably gained from the tactile stimuli on the abdomen, ability to withdraw sufficiently, and the energy expenditure from carrying the shell.

Fig. 3
figure 3

The median duration of the startle response to a moving shadow when crabs were approaching empty shells. All crabs were housed in the preferred species (Littorina) but these were either 50% or 75% of the optimum weight for each crab. The empty shells were all the optimum size, but some were the preferred Littorina shells, whereas others the less preferred Gibbula shells. (Reprinted with permission from Jackson and Elwood 1990)

Similarly, crabs are markedly influenced at an early stage by the quality of the empty shells. They were more likely to approach and contact if the empty shell was of the correct size (Elwood and Stewart 1985). They also showed shorter startle responses if they were approaching a preferred species of shell compared to those approaching an unpreferred species (Fig. 3) (Jackson and Elwood 1990). Thus, they collect information about the empty shell, in terms of species, shape and size, before contact is made with that shell, presumably by visual inspection (Elwood and Stewart 1985).

That crabs have good information about the exterior of the shell by the time they attempt to investigate the aperture was shown by offering shells with the aperture blocked. Persistence with the investigation, including attempts to remove the cement, was positively related to the quality of the offered shell, and inversely related to the quality of the current shell (Fig. 4) (Neil and Elwood 1986). This demonstrated that the crab had information about both shells without inserting the chelipeds into the aperture of the empty shell. However, because crabs gather information during approach, we cannot be certain that information is gained from moving the chelipeds over the exterior of the shell. Perhaps conducting experiments in the dark would solve this problem.

Fig. 4
figure 4

The median investigation times of shells with the apertures blocked. Those investigating optimal size (100%) shells persisted for longer than did those offered very small shells (25%). Furthermore, those crabs in optimum shells gave up the investigation sooner than did crabs in shells that were too small (25%). (Reprinted with permission from Elwood and Neil 1992)

How external and internal features of the shell are assessed was investigated when crabs were offered shells of preferred or unpreferred species that were (1) normal unmodified shells, (2) shells that had the apertures blocked with dental cement and (3) shells that were coated with dental cement on the exterior (but not in the aperture), and the two species shaped identically as an intermediate between species (Jackson and Elwood 1989a). Crabs in exp 1 and 2 progressed to the stage of aperture investigation (1) or attempted aperture investigation (2) more quickly if the shells were of the preferred species, and in the latter, persisted with attempts to dislodge the aperture blockage. That is, they discriminated between preferred and unpreferred species at that stage of external investigation. However, those in exp 3, which were offered shells with exteriors modified so they were like each other, could not discriminate the shells at that point by either visual or tactile means. However, those investigating the preferred species had shorter internal investigations prior to moving into the shell than those with the unpreferred species. This demonstrates species discrimination purely from information gathered during internal investigation, presumably due to the shape of the interior.

Crabs use different combinations of chelipeds and walking legs during aperture investigation, depending on the size of the offered shell and on their own current shell (Elwood and Stewart 1985). For example, when large shells were investigated the major cheliped was more likely to be used either alone or in combination with the minor cheliped and walking legs. Clearly, large shells may more easily accommodate chelipeds and walking legs, and which appendages can be inserted might aid size discrimination. Furthermore, there was a distinct difference in the appendages used depending on whether the crab was in a shell or not. Naked crabs had brief investigations and were much more likely to use the minor cheliped than the major cheliped. Here there seems to be a trade-off between the ease of information gain from cheliped use and the need to keep the major cheliped ready to defend from attack when naked (Elwood and Stewart 1985).

Experiments to determine how a terrestrial species assessed the aperture found no evidence to suggest that surface receptors were involved (Kinosita and Okajima 1968). However, if wax was added to extend the length of the chelipeds then shells were perceived as being smaller and abdomen insertion was less likely. The opposite occurred if the chelipeds were reduced in length. Thus, chelipeds may be used as “rulers” that assess the depth of the shell. Addition of wax to increase the width of the chelipeds also seemed to result in a perception of the shell being smaller than it was. The diameter of an aperture appeared to be assessed by flexion of the distal part of the chelipeds and if that flexion was inhibited by addition of wax at a joint then the aperture was perceived as being smaller and abdomen insertion was less likely for an otherwise suitable shell. Both chelipeds were used to gather information, but the major cheliped was found to be more effective than the minor (Kinosita and Okajima 1968). A final point to consider here, however, is that the minor cheliped can be moved through a greater arc within the aperture than can the major, so the proprioceptive input to the nervous system must differ between the two chelipeds. How these inputs are integrated remains to be investigated.

The stimuli used to indicate shell suitability must be frequently recalibrated, because the suitability of shells changes as the crab grows. Thus, a visual input that matches a suitable shell for a small crab will not match a suitable shell when the crab has grown. Furthermore, the way the chelipeds are used to assess shells must also change with age and sex, because chelipeds are sexually dimorphic (Teoh and Chong 2015) and grow at different rates in relation to body size. Thus, a male with larger chelipeds will not be able to insert the major cheliped as deep as can a female and will not be able to flex the cheliped as much as can a female, yet they might both assess the shell as equally suitable. The female preference for shells also changes when eggs are carried on the abdominal appendages, so the calibration of shell investigation must change at that time (Neil and Elwood 1985; Elwood and Kennedy 1988). Furthermore, when hermit crabs grow, they switch to larger species that might differ in shape (Elwood et al. 1979), and again the crabs must recalibrate the movement of chelipeds to the final fit of the shell. Thus, the process of assessment must be dynamic and recalibrated as the crabs grow, as sexual dimorphism becomes more pronounced, and when females carry eggs. Presumably, this is achieved when memories of specific movements of the chelipeds are associated with subsequent information from shell occupation. However, because of the different sizes of the two chelipeds each will require its own recalibration.

Identifying and dealing with obstructions within the shell

Experiments on shell selection typically used shells free of debris; however, on the shore, wave action might roll empty shells around in sand or gravel and some of that might enter aperture (Reese 1963). Hermit crabs encountering such shells detect the nature of the debris and show behaviour appropriate to those objects and the nature of the shells. For example, Elwood and Adams (1990) offered crabs empty shells, shells with sand, shells each with one piece of gravel, or shells with an unmovable mix of sand and dental cement inserted into the aperture but deep enough to enable cheliped insertion. Those encountering sand worked to extract the sand using two methods. The chelipeds were inserted one at a time and the sand extracted with a scraping motion against the wall of the inner shell. The crabs also held the shells, so the plane of the aperture was perpendicular to the substrate and the shell was then rotated, causing the sand to be poured out through the aperture. These activities resulted in a prolonged investigation and many more cheliped insertions were used than seen with empty shells. Those encountering gravel also used two methods. Some used their chelipeds in long-deep insertions and some crabs manoeuvred the gravel out of the shell. This usually required repeated attempts and it is possible that the gravel became lodged within the shell and the chelipeds appeared to dislodge the gravel. Other crabs used the rotation method seen with sand. Crabs with the blockage of sand and cement often attempted to scrape, as described for sand, but this was not successful. Some attempted to insert deeply in the shell, apparently attempting to dislodge the obstruction, whereas some rotated the shell. However, these crabs quickly recognised that the blockage could not be moved and typically gave up after brief attempts. This time was much shorter than when loose sand was encountered, which shows that crabs with sand or gravel recognised that the blockage could be moved and continued working to clear it.

Crabs encountering shells with loose sand inside always turned the shell in the clockwise direction (looking at the aperture) and that was effective in getting the sand to fall out (Elwood and Adams 1990). Had it been turned in the other direction sand would have moved along the spiral deeper into the whorls of the shell. All the shells used in that experiment had the normal dextral coiling of gastropod shells. However, when either dextral shells or those coiled in the opposite direction (sinistral) were offered, the former were always turned in the clockwise direction but many of the latter were turned anticlockwise (Imafuku 1994). That is, these crabs recognised the direction of the shell spiral and selected the direction of turning appropriate for removing sand. Thus, crabs show flexible responses when dealing with obstructions within the aperture of potential new shells, and assess the nature of the obstruction, the spiral of the shell and, judging from previously described experiments, the potential gain from the new shell. Whether this is due to a hard-wired decision-making system or if there is any suggestion of awareness is discussed below.

The final choice

At any time in the sequence of investigation and dealing with obstructions the crab might stop and walk away. Crabs in good shells investigating poor-quality shells often quit early in the sequence (Elwood and Sewart 1985; Elwood 1995) and thus with little investigation (Neil and Elwood 1986). The question is what cognitive process allows the decision to quit or continue further in the sequence. As noted, the initial information about the new shell is gathered visually, whereas that about the current shell most likely is from the experience of occupying that shell. If so, then a crab that quits immediately after an approach is somehow comparing visual information from the potential new shell with tactile experience from inhabiting the current shell. The next stage involves external investigation and then internal investigation, which presumably combine with the prior visual input, and again this is compared with the recent experience of occupying the current shell. That is, the crab appears to use various sources of information that predict the fit of the empty shell. The greater the potential gain in shell quality, the more likely and more quickly the crab decides to move in (Elwood and Sewart 1985). Furthermore, the lower the potential gain (or greater the loss) that might be made from the potential new shell, the more likely and quickly it makes the decision to reject the shell (Jackson and Elwood 1989a). Shells vary in many ways, not simply size, but somehow the crab must assess the overall value of a potential new shell in relation to the overall value of the current shell (Jackson and Elwood 1989a). That is, it must have some cognitive ability to compare two values, each of which comprises numerous variables, before deciding whether to reject the shell or move into it. This suggests some awareness. Five levels of awareness are proposed by Broom (2007), with “executive awareness” being the most complex. With this, it is proposed that information received at one time is related to a concept of events that would occur in the future. If crabs assess shells based on how they will fit in the future (should they move in), then this would seem to agree with the definition.

Should a crab move into the new shell, it then decides whether to investigate its old shell or move away in the new one. When the gain in shell-quality is high, it is unlikely that the crab will assess its old shell. However, when the gain is marginal or negative, then crabs are more likely to reassess their old shell and many then move back to the old shell. At this point, the crab has occupied both shells and thus should have very good information about their suitability. Now it would have a memory of occupying the old shell and have the current input of information from occupying the new shell. If the crab then assesses the original shell with its chelipeds, it might be able to compare that input with the memory of those same actions it recently used in assessing the new shell. That is, it will have memories of the fit of the old shell and of the aperture investigation of the new shell and could compare these with the current fit of the new shell and the current aperture investigation of the old shell.

Crabs have been shown to remember recently investigated and rejected shells (Jackson and Elwood 1989b). Thus, it seems reasonable to suggest that hermit crabs would use memories of recently occupied shells and compare that to the current information input from a newly occupied shell, and similarly for the aperture investigations. The decision, however, may not be easy and crabs may switch repeatedly between the two shells until it decides which to occupy. The process is complex and requires the integration of inputs of different sensory modalities. These relate to many variables that are assessed while crabs repeatedly switch between shells. Therefore, crabs must keep track of these inputs and memories as they relate to each of the shells. Perhaps this is best achieved with some form of awareness about which shell is which and how they compare.

Effects of the environment on shell choice

Because animals have limitations of their capacity for gathering information, other environmental stimuli might interfere with the shell assessment process. This was tested by observing crabs assess shells that had the aperture blocked when another shell, a stone or a larger or smaller crab could be seen though a clear barrier, but these stimuli had no overall effects on shell assessment (Neil and Elwood 1986). Other studies, however, have reported effects of additional stimuli. When a potential predator was behind a transparent mesh barrier, and predator odour was distributed through the tank, crabs inspected fewer of the available shells and moved into fewer shells than without the odour (Arce and Córdoba-Aguilar 2018). Furthermore, crabs in near optimum shells were distracted by predator odour cues from investigating shells, whereas those odours had little effect on crabs in poor shells (Tidau and Briffa 2019). That is, there was a trade-off between the need to improve shell quality and the need to avoid predators. Furthermore, anthropogenic noise reduced the number of crabs that moved into a new shell (Tidau and Briffa 2019). By contrast, Walsh et al. (2017) found that noise increased the motivation to acquire a new shell, because crabs approached with a shorter latency and spent less time investigating prior to shell entry than without noise.

Shells are used to reduce predation but selecting a protective, thick-walled shell might impose additional costs in carrying that shell (Rotjan et al. 2004). Thus, shell choice might vary depending on cues that indicate predators or not. However, different predators might employ different predation techniques and the optimal shell choice might be specific to the predator. This was investigated when hermit crabs were offered shells when odours of a shell-crusher predator or of one that peels away sections of the shell were present (Alcaraz and Arce 2017; Arce and Córdoba-Aguilar 2018). With cues of a shell-peeling predator the crabs selected large, loose-fitting shells. With this predator, the crab gets more protection if it can withdraw deep into the shell. By contrast, with the crusher predator, the crabs selected smaller, lighter shells. With the crusher predator the more effective defence is by running away and lighter, smaller shells enable a greater velocity (Alcaraz and Arce 2017). This plasticity in shell choice with different predator odours is remarkable. It would be interesting to see if crabs from an environment with no predators or just one species can make the discrimination and thus, we might investigate the role of experience in the development of the response.

Shell colour, and contrast with the background, might also have effects on shell selection (Briffa et al. 2008a, b). Although crabs might initially approach contrasting shells, simply because they are more easily detected, occupying such shells might expose crabs to visual predators. Thus, once housed, crabs assess the colour of potential shells and the environmental background and subsequently move to shells that match (Briffa et al. 2008a, b). Notably, when there are cues to the presence of predators the crabs become risk averse and become less likely to change shells, even when doing so might improve crypticity. However, crabs in cryptic shells are less prone to long startle responses to novel stimuli, which again suggests they are “aware of their current level of conspicuousness” and thus how the shell and environment interact (Briffa and Twyman 2011). Another example of shell choice being impacted by the environment concerns the oxygen content of the water. Crabs in hypoxic water become fatigued when carrying heavy shells and crabs in such conditions switch to lighter, smaller shells (Cote et al. 1998).

Hermit crabs often inhabit environments, where obstacles are abundant, and they face problems, because large shells might make moving through gaps difficult. To cope with this, the crabs might alter their shell choice in a way that relates the external size of the shell to the environmental obstructions. The possibility that crabs assess external obstacles and shell extremities was examined with terrestrial hermit crabs by placing them in a corridor that had obstacles placed alternately on the left and right side of the path (Fig. 5a) (Sonoda et al. 2012). When those obstacles were close to each other, the crabs could only pass along the corridor by turning the shell axis so that they could navigate through the gaps. With larger gaps the crabs turned less (Fig. 5b). To test if there was an awareness of the shell extremities, a square of plastic was glued to the side of a shell such that an extension was created (Fig. 6). When this was attached many crabs took a few minutes to adjust their balance and regain their ability to walk. When placed in the corridor, the crabs made turns of a greater extent to get the extended shell through the gaps (Fig. 5c). The crabs seemed to judge the gap visually and then base the degree of turning upon that assessment. At the very least it shows the ability to relate an awareness of the altered shell dimensions with a specific environmental feature.

Fig. 5
figure 5

a Plan view of corridor with starting point (SP) and distance between partitions (d) (note that d0 is a smaller distance than d5 and that is smaller than d10). b Crabs moved from right to left through the partitions. Arrows represent crabs’ body axis orientations. c Turning angles of the crabs without plates were greater when the gap between partitions was small, (top) and turning angles were greater when a plate was attached (bottom). (Reprinted with permission from Sonoda et al. 2012)

Fig. 6
figure 6

Crab (Coenobita rugosus), with a plastic plate attached to the shell. (Reprinted with permission from Sonoda et al. 2012)

This idea about awareness of environmental restrictions was further investigated by giving social terrestrial crabs a choice of two “shells”, made by 3D printing, within a small chamber that had a hole only large enough to allow one of the shells to pass (Krieger et al. 2020). The shells differed in terms of the crab’s normal preference, but only the less preferred shell would enable the crab to escape from isolation. The choice of shell in this situation was compared to that in a control that allowed either shell to pass through a larger hole. In the control, the crabs selected the shell that was expected to be a better fit for the crab. By contrast, when the escape-hole was small crabs shifted their preference the normally non-preferred shell, which allowed escape. These data suggest some degree of forward planning and awareness of how to solve the problem. Crabs would even occupy shells that had spines on the inside, which were usually strongly avoided, to escape from the chamber.

Abandoning a shell

Leaving a shell is dangerous, particularly if there is little opportunity to access a new one (Elwood and Neil 1992). Nevertheless, in several contexts, crabs will abandon their shells. One situation in which this occurs is if the shell ceases to be mobile by being buried or trapped (Turra and Gorman 2014). Those crabs that are buried in sediment, and in danger of asphyxiation, abandon shells within minutes, whereas those in shells that are simply clamped to make them immobile might take more than an hour (Gorman et al. 2015). That is, crabs appear to assess the risk of remaining in the shell. Furthermore, crabs in immobilized shells of the required size were more reluctant to get out compared with those in shells that were much too small, and crabs in intact shells took longer to abandon the shell than did those in damaged shells. Crabs that had been induced previously to abandon shells and then provided with a new one abandoned their shells more quickly in subsequent tests. Those that had inhabited the current shell for a short time were also quicker to abandon trapped shells. Finally, the odour of predated gastropods, which may indicate available shells, elicited faster abandonment. That is, the crabs appeared to integrate information about the potential loss in terms of shell quality, the potential danger from the situation, experience of surviving shell abandonment in the past, the familiarity with the current shell, and the potential of finding a new shell (Gorman et al. 2015). They trade-off one requirement with another.

Crabs may also abandon a shell if there is a disturbance that causes discomfort to the delicate abdomen (Lancaster 1988). This was observed when a large naked crab was induced to occupy a large shell in which a very small crab had been placed. Shortly after moving into the shell, the large crab jerked violently and then emerged. It then made a thorough inspection of the inside of the shell, feeling around with its pincers, whereupon it re-entered the shell. There was a further period of jerks and twitches during which the crab made vigorous attempts to get out of the observation chamber (personal observation). This suggests that movements of the small crab within the shell was aversive.

This disturbance within the shell may be simulated by drilling small holes in empty shells and fixing small wires so that, when occupied, electric shocks can be applied to the abdomen of the crab (Appel and Elwood 2009a, b; Elwood and Appel 2009; Magee and Elwood 2016). When low voltage shocks were applied, the crabs showed jerking movements, but increasing the voltage caused some crabs to abandon their shells. This demonstrates that the shock, as with the small crab noted above, is aversive. At first sight it appears that abandoning the shell is a reflex response. However, the crabs trade-off escaping from the shock with other requirements, and thus show that the response is a decision rather than reflex. For example, crabs emerged from the less preferred species of shell at a lower voltage than they did from the preferred species (Appel and Elwood 2009a). Furthermore, when the voltage was kept constant, they were more likely to abandon the less preferred species (Elwood and Appel 2009). They were also less likely to abandon the shell if there was an odour of a predator in the water (Magee and Elwood 2016). Such trade-offs have been regarded as one sign of consciousness (Birch et al. 2020) or sentience (Elwood 2019; Godfrey-Smith 2020). When crabs emerged from their shell after being shocked, they often turned and touched their abdomen with their chelipeds, an activity only noted in this specific context. Again, attending the site of a wound indicates some degree of awareness and thus is considered a sign of sentience (Broom 2007; Elwood 2019). Some crabs moved away from their shell and attempted to climb the walls of the small observation chamber. Some remained naked for the period of observation, whereas others returned to the shell, often preceded by prolonged feeling inside the shell with the chelipeds (again, note the similarity to the observation with two crabs in one shell). Furthermore, some crabs rapped the empty shell with their naked abdomen (Appel and Elwood 2009a, b), which is an activity used to persuade another crab to get out of a shell (Dowds and Elwood 1985) and is not normally used against empty shells. Searching within the shell appears as if the hermit crab is attempting to find the cause of the aversive stimulus and the rapping suggests that the crab is attempting to evict a small crab. If the crab remained within the shell, however, they showed a marked shift in their motivation to keep that shell. This was demonstrated by offering an empty shell to crabs shortly after the shock and comparing their responses with crabs in wired shell but without electric shock (Elwood and Appel 2009). The shocked crabs were more likely to investigate the new shell and more likely to move into it compared to those not shocked. The shocked crabs also approached with a shorter latency and used fewer insertions of their chelipeds compared to those not shocked, demonstrating that there was a clear reduction in the motivation to keep the shell in which they had been shocked. This difference in the response towards the offered shell was seen if there was a delay between the shock and the shell being offered for up to 24 h (Appel and Elwood 2009b), thus showing a long-term shift in motivation induced by electric shock. These responses are not mere nociceptive reflexes; rather they are consistent with the predictions of a pain experience and, hence, sentience (Elwood 2019).

Hermit crabs may also get out of shells during shell fights. Here one animal takes the role of attacker, approaches, and grabs the shell of the opponent. The opponent is termed the defender, because it usually shows some resistance to being removed from its shell. The attacker might escalate the contest. In marine species this involves holding the defender’s shell and repeatedly pulling the two shells together in a vigorous activity called “shell rapping” (Fig. 7a). The rapping is organised in bouts in which the gaps between raps are short, and the bouts are separated by pauses that are longer than the gaps (Briffa et al. 1998). The attacker might also hold and rock the defender’s shell in a less vigorous activity (Dowds and Elwood 1983; Edmonds and Briffa 2015). During the fight, the defender is not passive, and it might move its chelipeds through an arc within the aperture of its shell, and this might cause the attacker to release its grip on the defender’s shell and give up (Hazlett 1970). Should the defender give up, however, it signals to the attacker by rapidly tapping the attacker with the walking legs. The attacker then grasps a cheliped of the defender with one of its own chelipeds and pulls the defender from the shell (Fig. 7b) (Dowds and Elwood 1983). For this to happen the defender must release its abdominal grip on the columellar of the shell (Elwood and Neil 1992). Once the defender is removed the attacker typically examines the interior of the now empty shell and may move into that shell. However, it might then move back to its original shell. Eventually, the attacker makes its choice of the two shells and moves away, leaving the defender to take whichever shell is left. Here I examine information that affects decisions made by attackers and the defenders.

Fig. 7
figure 7

a Two Pagurus bernhardus fight, the attacker being visible, but the defender has withdrawn into its shell. The attacker has turned the defender’s shell to access the aperture. In this position the attacker holds the defender’s shell and repeatedly pulls it towards its own shell and moves its own shell to hit the two shells together, known as “shell rapping”. b After several bouts of shell rapping the defender releases its grip on the columellar of the shell and is pulled out of the shell. (Photos by R W Elwood Reprinted with permission from Elwood and Neil 1992)

Information available to the attacker in making fight decisions

The larger crab usually takes the role of attacker (Dowds and Elwood 1983, 1985), and displays of the chelipeds are influential in this decision (Neil 1985; Elwood and Neil 1992). Larger crabs are more likely to attack if they are in poor-quality shells, but the larger crabs appear not to assess the defenders’ shells at that early stage of the contest (Dowds and Elwood 1983). Note that this is different to when crabs are approaching empty shells as discussed above. However, the quality of the attacker’s shell and the defender’s shell both strongly influence whether the attacker escalates the contest, with attackers in poor shells encountering defenders in shells that would be suitable for the attacker being particularly likely to show shell rapping (Dowds and Elwood 1983). Attackers also show shorter startle responses to a novel stimulus if they are contesting high-quality shells (Elwood et al. 1998), and attackers showing short startle responses, indicating high motivation, were more likely to win (Briffa and Elwood 2001a). Thus, the attacker gathers information from the exterior of the defender’s shell. The encounter is more likely to result in an eviction of the defender if the attacker might gain in shell quality, because such attackers are more persistent (Dowds and Elwood 1983; Elwood and Glass 1981).

Attackers also monitor their own contest performance and might adjust their behaviour. This was demonstrated when the attacker’s shell had a rubber solution painted on to either the area used in rapping or an adjacent area. Attackers with dampened raps reduced the number of raps per bout but continued for more bouts than did those in shells that had not been dampened (Briffa and Elwood 2000a). Furthermore, crabs with dampened raps used more shell rocking (Edmonds and Briffa 2015). These findings suggest that the crabs perceived the power of their raps by the feedback from the impact of the shells. It is possible that cues from the defender produce the change in the attacker, but this is unlikely, because attackers change tactics early in the contest when the defender is withdrawn in its shell. Regardless, attackers in dampened shells were not as effective in winning the contest compared with those in normal shells (Briffa and Elwood 2000a; Edmonds and Briffa 2015). This is similar in some respects to contests involving naked attackers that use the rapping movement of the abdomen but without much impact. Naked attackers persist for longer than crabs in shells but with little success (Dowds and Elwood 1985).

Rapping is costly for the attacker and causes fatigue. Fights that were interrupted before rapping occurred, or after two, four or six bouts of rapping showed that lactate levels rose rapidly from bout to bout (Briffa and Elwood 2005b), and energy reserves became depleted (Briffa and Elwood 2004). Attackers that gave up had higher levels of lactate at the end of the fight than did those that won, suggesting that lactate restricts the ability to continue rapping (Briffa and Elwood 2001a, b, 2004). Successful attackers also had higher levels of the oxygen-carrying protein, haemocyanin (Mowles et al. 2009). Furthermore, attackers held in low-oxygen water prior to the contest were less able to fight effectively and less able to evict the defender (Briffa and Elwood 2000b). Fatigue not only affected the persistence by the attacker but also reduced the attacker’s ability to rap quickly within each bout. Inter-bout intervals also increased, and the power of raps reduced as the fight progressed (Briffa et al. 1998; Briffa and Elwood 2000c, 2001b, 2002, 2003). However, there was no set threshold of fatigue that caused the attacker to give up, because attackers that could make a large gain in shell quality persisted for longer and had higher levels of lactate (Briffa and Elwood 2005b). This suggests that the attacker monitors its level of fatigue and trades-off the build-up of lactate against the potential gain from victory.

The quality of the attacker’s shell clearly affects the motivation to obtain the defender’s shell. However, it might also affect the fighting ability. The attacker’s shell is essentially a weapon that is used to strike against the defender’s shell. If the attacker’s shell is very small, it might be easier for the attacker to move in the striking motion than if the shell is too large and heavy. However, crabs in very small shells might have a reduced ability to maintain a water-flow for respiration (Doake et al. 2010). Indeed, although crabs in very small shells are highly motivated to attack, they fatigue very quickly, so are not more successful despite the potential gain should they evict the defender (Doake and Elwood 2011).

These findings illustrate the complex relationship between fighting ability, fatigue and information about both shells that can occur in hermit crabs. Another example can be found with the size of the chelipeds, which show variation in relation to body size (Arnott and Elwood 2010). As noted above, cheliped displays are important in determining which crabs will become the attacker and hence the likely outcome in terms of gain in shell quality (Neil 1985; Elwood et al. 2006). However, there are costs to carrying and displaying large chelipeds, because crabs with larger than expected chelipeds have higher than average lactate levels that will impede their fighting ability (Doake et al. 2010).

Interactions between crabs not only allow information about the other crab to be gathered, that information is remembered. That is, when a crab was exposed to another crab and its shell it subsequently reacted differently to that crab compared to a novel crab and shell (Gherardi and Atema 2005), but the memory was based on odours from the crab rather than from the shell (Gherardi et al. 2005). After being exposed to a crab with a good shell, the focal crab subsequently spent more time investigating a novel shell that had the aperture blocked than if it had been exposed to a crab in a poor shell. This discrimination was not seen with odours of unfamiliar crabs with good or poor shells (Gherardi et al. 2005), and good or poor shells per se were not discriminated by odour. This demonstrates the remarkable ability of hermit crabs to associate the odour of a particular crab with the quality of the shell that stimulus crab occupied during the initial encounter. That association increases the motivation to obtain a new shell as evidenced by the increased persistence with a shell that had the aperture blocked.

Gains, losses, and the defender’s decision

Defenders resist an attacker for longer if they are in excellent shells for themselves. Furthermore, defenders sometimes flick their chelipeds within the shell aperture, presumably to disrupt the attack, and this is more common when the defender is in a good-quality shell (Dowds and Elwood 1983). However, the defender’s shell also influences the attacker’s motivation, so contest dynamics might be due to the motivation of either the defender or the attacker. To examine specific effects on the defender, the information about shell quality was made private to the defender by forcing crabs to inhabit shells that had sand glued to the inner whorls. Such shells were normally avoided, but the sand could not be detected by potential attackers. Defenders in sandy shells showed fewer cheliped displays prior to the attacker making contact, presumably because it was more willing to be attacked (Arnott and Elwood 2007). Furthermore, the defenders in sandy shells gave up the contests more quickly than did defenders in normal shells (Arnott and Elwood 2007). Thus, the defender knew about the quality of its own shell and if that was very low, it acted to enhance the possibility of shell exchange.

It is possible, however, that shells might affect the crab’s ability to defend against an attacker (Burciaga et al. 2021). Defenders in shells that had part of the columella experimentally removed were less able to defend those shells even though there was no bias against those shells in choice experiments. Thus, it was not a motivational difference that accounted for the lower defence rate; rather, it was the reduced ability to grip on the columella.

It would benefit the defender if it had information about the suitability of the attacker’s shell, because that would allow the defender to accurately assess the potential loss or gain, and that might influence how much it resists eviction. As noted above, attackers can gain information about both shells, but defenders spend most of the contest withdrawn within their shells and are not able to feel over the opponent’s shell. Nevertheless, Hazlett (1978) found that variables associated with the potential gain to the defending crab were more reliable in predicting the duration of a shell fight than were variables associated with the attacking crab. The defending crab appeared to assess the attacker’s shell and, if an improvement in shell adequacy could be gained by the defender, an exchange occurred more quickly. It was suggested that the term ‘negotiation’ would be more appropriate than ‘aggression’ to describe these interactions (Hazlett 1978). However, other experiments failed to replicate this finding (Elwood and Glass 1981; Dowds and Elwood 1983 but see Hazlett 1987 and 1989). One key difference in these experiments, however, was that Hazlett (1978) used large and hence old hermit crabs, whereas Elwood and Glass (1981) and Dowds and Elwood (1983) used small specimens that were young. When intermediate-size and hence intermediate-age crabs were used, defenders demonstrated the ability to assess the attacker’s shell, presumably by vision during the early stages of the contest. This suggests that the cognitive abilities required to maximise gains and minimise losses develop with age and, presumably, practice (Doake and Elwood 2011). Thus, although young crabs can assess empty shells from a distance (Jackson and Elwood 1990), they appear to be distracted from shell assessment if another crab is in a shell (Doake and Elwood 2011).

Why does the defender quit?

When defenders give up in shell fights, they do so more quickly than when a shell is simply immobilized, so it seems that being held by the attacker is not a major component of this decision to quit. The shell rapping appears to be the key to persuading the defender to give up. Attackers that persisted with bouts of rapping, especially those that put more raps per bout and faster repetition within bouts and with shorter gaps between bouts, were more likely to evict the defender (Briffa et al 1998; Briffa and Elwood 2000b). Power is also critical, because when the raps were dampened by coating the attacker’s shell with a rubber solution, the defenders were less likely to give up (Briffa and Elwood 2000a). Furthermore, attackers that managed to repeatedly strike the shells together with a high degree of accuracy were more likely to evict the defender (Lane and Briffa 2020). Thus, power, speed, skill, and ability to persist in rapping by the attacker are the main components that lead to the defender quitting.

Studies on shell fights have frequently suggested that raps were signals of resource holding power and that the defenders responded to that information (Briffa et al 1998; Briffa and Elwood 2000a, b). However, if rapping simply contained information rather than having a physical effect on the defender, then the defender could simply wait until the attacker became too fatigued to continue. Two possibilities for why the defender gives up have been investigated. First, it is possible that because the defender withdraws into its shell, it becomes depleted of oxygen. However, keeping the defender in low-oxygen water before a contest had no effect on its ability to retain the shell (Briffa and Elwood 2000b). Furthermore, lactate levels were no higher in defenders that gave up compared to those that successfully resisted (Briffa and Elwood 2001a, b), suggesting that they had not resorted to anaerobic respiration and that oxygen levels were not important in the defender’s decision to quit.

The second possibility is that rapping has a direct effect on the abdominal muscles such that they cease to function, and the defender can then be easily extracted by the attacker (Chapple 1993; Briffa and Elwood 2000a, b; Lane and Briffa 2020). However, this would not explain why the defender’s shell quality has marked effects on the timing of the defender giving up (see below). If the defender is incapacitated by the rapping, then other motivational factors should have no effect. It should be pulled out by the attacker as soon as the muscles cease to function. Rather, we see that the potential gain or loss of shell quality is traded off against the decision to evacuate from the shell.

Here, I suggest a third possibility. Rapping might be aversive to the defender and that giving up is a way to end this aversive stimulus. It would thus have similarities to the repeated minor electric shocks to the abdomen that can cause the crab to get out of the shell. The probability and timing of getting out of the shell are traded-off against the shell quality when electric shocks are applied (Appel and Elwood 2009a; Elwood and Appel 2009), and thus is like trade-offs in shell fights (Dowds and Elwood 1983; Arnott and Elwood 2007). That is, the better the shell for the defender, the longer it resists eviction. This suggestion of aversion also accounts for the findings that frequent powerful rapping is more likely to be effective and accurate positioning of the strikes on the shells is also more effective than more scattered hits (Lane and Briffa 2020) and strikes that are well executed appear to be effective (Briffa and Fortescue 2017). These powerful and persistent hits might provide adverse stimulation to the delicate abdomen of hermit crabs. Studies on contest outcomes in a broad range of taxa have generally focused on the balance on costs and benefits of winning and losing and have rarely considered if feelings of pain or aversion might be caused by fight activities, although one recent review has suggested that fights result in negative affective states (Crump et al. 2020).

Additional evidence that mechanical stimulation of the abdomen is aversive comes from observations when crabs are experimentally removed from their shells (Dowds and Elwood 1985). We do this by cracking the shell in a bench vice, which typically breaks away the large whorls but leaves the crab still holding to the rear part of the shell. We then hold this small portion of shell and touch the abdomen of the crab with a metal seeker. This tactile stimulation causes the crab to release its hold and escape from the stimulus by leaving the remnant of the shell. Furthermore, if a nylon fibre is used to touch the abdomen through a small hole drilled into an otherwise intact shell, the crab will release its hold and escape from the shell (Lancaster 1988). These observations indicate sensitivity to mechanical stimulation, which is also likely to occur with repeated, powerful rapping.

Vacancy chains and prediction of future events

When a crab in a poor-quality shell finds a better empty shell and moves in, it discards its old shell. That is not the end of the story, however, because the old shell might then be encountered and taken by another crab, and it too will discard its existing shell. Thus, there might be a cascade of shell changes by different crabs following the initial shell change, a process viewed as a vacancy chain (Chase 1991). Furthermore, in shell fights the attacker might evict the defender and take its pick of the two shells. The defender is usually able to take whichever shell the attacker did not select and does so by waiting nearby for the attacker to decide and move away. The defender might attempt to take the currently empty shell, but the attacker uses cheliped displays to keep the defender away (Dowds and Elwood 1983). On the shore, however, crabs often occur in large aggregations of 50 or more crabs per m2, in which case the naked defender might be vulnerable to other, nearby crabs. It is possible that the naked crab could be forced to move away by these other crabs, and thus not be able to immediately take the discarded shell. The shell discarded by the attacker might then be available to another crab to investigate and take (Elwood and Neil 1992). Again, we might see several crabs change shells within a vacancy chain. Rotjan et al. (2010) refer to these as asynchronous vacancy chains, and contrast them with synchronous vacancy chains, which have features that indicate a high cognitive ability and forward planning.

If a small terrestrial crab encounters an empty shell that is too large, the crab will reject that shell. However, the crab might not move away from the site but might remain nearby. It is possible that another crab might find the shell and again it might be too large for that crab, and it too might remain. Crabs are attracted by other waiting crabs so several might wait near the shell that is too large for them until a larger crab arrives. At this time the waiting crabs arrange themselves in size order, and should the large crab take the empty shell, the first crab in line, i.e., the largest of the waiting crabs, will take the shell discarded by the large crab. The crab will discard its original shell, which then becomes available to the second in line and so on until all the crabs switch shells and the smallest crab discards its very small shell. This behaviour results in all the crabs gaining in shell quality (Rotjan et al. 2010).

In other cases, terrestrial crabs appear to predict that a fight will occur between two large crabs and form an assemblage. They wait for one crab, typically the largest in the group, to attack another to attempt to take its shell. Shell fights in terrestrial species differ from those of marine species and comprise prolonged pulling of the defender by the attacker combined with rocking the defender’s shell. Other crabs assemble in a line, again in size order, and wait until the defender is evicted. At that point, the victor moves into the vacated shell and the victor’s discarded shell might immediately be taken by the first crab in the line. Shells are then swapped down the line leaving the evicted defender with an unsuitable shell, and such crabs may not survive for very long (Laidre 2014). The main point is that crabs appear to predict that shells will become available and arrange themselves so that all crabs in the chain might improve shell quality. That is, crabs appear to show executive awareness as defined by Broom (2007).

An additional complexity with these fights and vacancy chains arises, because two crabs might cooperate in evicting a crab in a large shell (Laidre 2021). This occurs when one crab initiates a fight and is then assisted by a second crab. The two attackers typically pull at the victim simultaneously but sometimes they take turns. If they are successful, the evicted crab is pushed away from the vacated shell and one of the coalition moves into that shell. This enables the second attacker to take the now empty shell of the crab that has just changed shells. Each member of the coalition has a chance to obtain a better shell in this process (Laidre 2021) but there is no evidence of advance planning or of the two crabs associating before they cooperate. The coalition seems to form opportunistically with the second attacker taking advantage of the fight. Nevertheless, it is likely that coalitions are more successful in evicting the defender so there appears to be a mutual benefit. Often, however, other hermit crabs will approach during the fight and stay nearby. Should an eviction occur, they might take turns in moving shells.

Sentience and brains

Despite the signs of sentience noted above, the idea that invertebrates might have feelings and awareness is often dismissed, because their brains are thought to be too simple and lack the precise structures found in humans that are involved in sentience (Rose et al. 2014; Key 2016). It is stated that neuronal structure determines function, so animals with different structures cannot have the same function, a position clearly at odds with disparate taxa having similar sensory abilities (Elwood 2011). However, there is no denying that arthropod brains are smaller than those humans; however, they do have a high degree of complexity and specialized function (Barron and Klein 2016). Indeed, areas of the insect brain have similarities in functional architecture to that noted in vertebrate midbrains, for which a role in sentience is claimed (Barron and Klein 2016). The insect mushroom bodies are important for learning and memory and are thought to be homologous to the hemiellipsoid bodies in crustaceans (Strausfeld et al. 2020). A comparative study of decapod brains demonstrates considerable variation in the size of the hemiellipsoid bodies, relative to other brain areas. They are particularly developed in hermit crabs and are thought to be involved in spatial awareness, exploration, and homing; however, the role of these brain areas in shell assessment has been considered only briefly (Kreiger et al. 2012). In comparing true crabs and hermit crabs the hemiellipsoid bodies are of similar size but those of hermit crabs show a clear subdivision into two core neuropils and a cap, which are not seen in true crabs. These subdivisions are even more marked in terrestrial species of hermit crabs, and it is likely that this variation reflects differences in sensory abilities and behaviour (Kreiger et al. 2012). The study of hermit crab brains, and those of other decapods, is in its infancy, but nevertheless suggest a complexity sufficient for sentience.

Conclusions

Sentience is usually defined as the ability to have “feelings”, especially that of pain (Walters 2018; Passantino 2021). Assessing if pain occurs in animals depends on various criteria being fulfilled (Sneddon et al. 2014), some of which have been directly tested with hermit crabs. For example, we see trade-offs between avoidance of noxious stimuli and other motivational requirements (Appel and Elwood 2009a; Elwood and Appel 2009; Magee and Elwood 2016), direction of attention toward the afflicted site (Appel and Elwood 2009a), and long-term motivational change as shown by the increased motivation to move shells if shocked within a shell (Elwood and Appel 2009; Appel and Elwood 2009b), and these are consistent with pain. There is also evidence from a range of other decapod species, which includes physiological stress responses (Fossat et al. 2014; Elwood and Adams 2015), rapid avoidance learning (Okada et al. 2021; Magee and Elwood 2013), reduced risk-taking (Fosssat et al. 2014, 2015), and local anaesthetics reducing responses (Barr et al. 2008). There are thus grounds for suggesting that hermit crabs experience negative feelings. Indeed, there are grounds to suspect that hermit crabs inflict aversive experiences to defenders in shell fights and that defenders give up because of those negative feelings. That is, the data are consistent with the normal definition of sentience.

However, Broom (2007) adds four more criteria for sentience to that of feelings. First, the animal should have some degree of awareness. Awareness in hermit crabs is suggested by the directed attention specifically at the site of noxious, potentially painful, stimulus noted above (Appel and Elwood 2009a, b). We also see hermit crabs being aware of the effectiveness of their actions during the escalated phase of a contest. Crabs that had their raps dampened rapidly shifted tactics (Briffa and Elwood 2000a; Edmonds and Briffa 2015). However, perhaps more convincing are the observations of crabs adjusting to extensions of shells so they can move through a complex environment (Sonoda et al. 2012), identifying the nature of obstructions in shells and acting accordingly (Elwood and Adams 1990), and the turning of dextral and sinistral shells in the appropriate directions to pour out sand (Imafuku 1994). Of special note is the ability to solve a problem by changing to a normally unpreferred shell so that the crab can escape through a small hole (Krieger et al. 2020).

Second, the animals should be able to assess risks and benefits. This is shown when crabs evaluate empty shells and make complex assessments of the potential benefits of switching shells. Risks seem to be assessed when odours of specific predators lead to a choice of shells that offer greater protection (Arce and Córdoba-Aguilar 2018). Risks are also assessed when the size of an opponent is evaluated in contests. Furthermore, defenders modify their resistance to the attack due to the benefits of keeping their shell compared to the benefits of swapping shells. Note also that crabs abandon their shells more quickly if the shells are buried in sand, with a risk of suffocation, than if just clamped so they cannot be moved (Gorman et al. 2015). Of course, crabs probably use rules of thumb rather than calculations. Nevertheless, assessments are made that approximate risks and benefits and thus fit this criterion.

Third, they should remember their own actions and their consequences. This is indicated by the way hermits assess shells using movements of the chelipeds and walking legs on the outside and inside of empty shells, the input of which will then be calibrated against the fit of the shell after moving in. Furthermore, hermit crabs remember other crabs with which they interact and even remember the quality of the shell that crab occupies (Gherardi et al. 2005). Crabs also quickly adapt to extensions of their shells so they can move through the environment. This must involve some feedback as to the consequences of their actions (Sonoda et al. 2012).

Fourth, there should be an ability to evaluate the actions of others in relation to self and third parties. This is suggested by observations of terrestrial crabs that appear to predict a fight will occur between two other crabs and then form a vacancy chain of decreasing sizes with other crabs. Should one crab manage to evict the other crab, then the crabs in the chain take turns in swapping shells. This also occurs when a terrestrial hermit encounters an empty shell that is too large. It and other crabs might wait nearby for a large crab to take the shell and discard its original shell, which is smaller than the large new shell (Rotjan et al. 2010; Laidre 2014). That shell is then available to be taken by the largest of the waiting crabs. It is not clear what cognitive processes take place in guiding these decisions. Does the waiting crab have a concept that a shell might become available, and what is the role of learning, possibly social learning? Does the probability or duration of waiting depend on the current population density because that would influence the probability of a shell becoming available? It appears to be a problem suitable for experimentation. However, the data are consistent with ideas of evaluation of self and third parties.

Thus, findings from numerous studies on hermit crabs appear to be consistent with the five criteria of sentience set out by Broom (2007). Hermit crabs also show great perceptual richness and fine evaluative richness, which are suggested by Birch et al. (2020) to be dimensions of consciousness. Furthermore, Cabanac et al. (2009) suggest that having to deal with complex environments and make complex decisions promoted the evolution of consciousness as a means of optimizing behaviour. Hermit crabs show complex decisions. They also show trade-offs between avoiding shock and avoiding predators, such trade-offs being considered as a sign of consciousness when observed in vertebrates (Cabanac et al. 2009). In addition, there are elements of forward planning and self-awareness, and thus hermits appear to show some of the building blocks of consciousness (Birch et al 2020). However, while some components of consciousness might be suggested, I do not seek to define that state or claim that hermits are conscious. Nevertheless, when hermit crabs deal with numerous problems associated with their use of shells, their behaviour and cognitive abilities are consistent with expectations of sentience.