[RPG] Can you replace a racial trait cantrip when leveling up

cantripsdnd-5eracial-traits

The Tiefling has the Infernal Legacy racial trait, which grants them the Thaumaturgy cantrip.

In the PHB, it says (emphasis mine):

[…] when you gain a level in this class, you can choose one of the warlock
spells you know and replace it with another spell from the warlock
spell list, which also must be of a level for which you have spell
slots.

Suppose I have a Tiefling Warlock that has just reached level 2. Can I replace the Tiefling's Thaumaturgy cantrip (from their racial trait) with another Warlock cantrip? Or can I only replace specifically Warlock spells of level 1 and higher?

Best Answer

No, for two different reasons.

Most classes cannot replace cantrips at all. Even warlocks and sorcerers can only replace spells of a level for which they have spell slots, which excludes Cantrips since you don't have any 0th level slots.

But even if you could replace cantrips, as the Unearthed Arcana Artificer can, you still can't replace racial cantrips, because your class ability doesn't allow for it.

The warlock class feature says, as you quoted:

choose one of the warlock spells you know

Cantrips you gained from your race aren't warlock spells.

Similarly, the Artificer's ability says:

you can replace one of the artificer cantrips you know

Again, racial spells aren't artificer spells.