You attempt to wipe the memories from the mind of one creature that you touch. The target must make an Intelligence saving throw. On a failed saving throw, the target takes 12d6 psychic damage and the target's mind is sent reeling as it attempts to hold onto its memories. On a successful saving throw, the target takes half damage and can't take reactions until the start of its next turn, but is otherwise not affected by the spell, and the spell ends.
Creatures whose minds are reeling from this spell are stunned. A creature reeling from this spell must also make another Intelligence saving throw at the end of each of its turns. On a failed saving throw, it takes 6d6 psychic damage. If it saves against this spell three times, the spell ends. If it fails saves three times, it becomes unconscious until the spell ends and it stops making these saving throws. The successes and failures don’t need to be consecutive; keep track of both until the target collects three of a kind.
If you maintain your concentration on this spell for the entire possible duration, the target loses all of its memories and the spell ends. It gains one level of exhaustion, and if it isn't unconscious, it becomes unconscious. It stays unconscious for at least 1 hour after losing its memories, regardless of its hit points.
A creature who has lost its memories knows nothing about themselves or their past, but it remembers most general ideas about the way the world is arranged and how things work. It retains its inclinations, likes, dislikes, and fears (towards food, ideas, people, etc.), but it will not know of these feelings until it encounters them, and these feelings are much more malleable and easier to change than a creature who has memories to ground its feelings in. It retains all its skills and abilities, including spellcasting, though it will not initially remember that it has most skills or abilities.
Once a creature has lost its memories due to this spell, it will develop a new (perhaps similar) identity and begin forming new memories without any issue, but it will not naturally regain the memories it lost. Once a year it must make an Intelligence saving throw with disadvantage. It may also make this saving throw on rare occasions where it encounters something that might spark its memory, at your DM's discretion. On a successful saving throw, it recovers all its lost memories, which causes it to become stunned until the end of its next turn.
The spell can also be ended by greater restoration, heal, or wish cast as an 8th-level or higher spell.
* - (an umarked slate)
Like this spell!!
What if the creature meets someone it might remember?
if the damage were lower, this could be a 8th or even 7th level spell, perhaps one that could be upcast for higher damage
edit: i really, really like the spell btw
I found this spell while working on a campaign hook where the entire party awakes after suffering from an attack that left them without any knowledge of who they are or what they were doing. They have to find the clues to regain their memories and finish the quest.
So I like having them need to roll when they encounter certain things to see what the character remembers. And maybe doling out the information piecemeal.