Tier 3 Epic transmutation

Casting Time: 1 action
Range: Touch
Components: V, S, M (a doppelganger embryo)
Duration: Concentration, up to 10 minutes

Choose one creature or nonmagical object you can see within reach. You transform a creature into a different creature, a creature into an object, or an object into a creature (the object must be neither worn nor carried by another creature). Mythic creatures are immune to the effects of this spell. An affected target gains temporary hit points equal to the hit points of its new form. These temporary hit points cannot be replaced by temporary hit points from another source and the target reverts to its normal form when it has no more temporary hit points or when it dies. If the spell ends before then, the target loses all its temporary hit points and reverts to its normal form. At the end of each of its turns, a transformed Epic creature can attempt a Wisdom saving throw to end the effect. After three successful Wisdom saving throws, the effect ends. If you concentrate on this spell for its full duration, its effects become permanent and a creature can no longer attempt saving throws to end the effect. As an action, you can touch a creature affected by this spell to force it to assume a different form.

Creature into Creature. If you turn a creature into another kind of creature, the new form can be any kind you choose whose challenge rating is equal to or less than your character level. A creature cannot be turned into a mythic creature under any circumstances. You can choose to have the target’s game statistics, including mental ability scores, completely replaced by the statistics of the new form and the target assumes the new form’s alignment and personality. Otherwise, the target retains its alignment, along with its Intelligence, Wisdom, and Charisma scores. Additionally, the target retains its skill and saving throw proficiencies, in addition to gaining those of the creature—if the creature has the same proficiency as the target, use whichever bonus is higher.

The target is limited in the actions it can perform by the nature of its new form, and it can’t speak, cast spells, or take any other actions that require hands or speech, unless its new form is capable of such actions. The target’s equipment can meld into the new form at your discretion. The target can’t activate, use, wield, or otherwise benefit from any of its equipment unless that form could also do so.

Object into Creature. You can turn an object into any kind of creature, as long as that creature is not a mythic creature and the creature’s challenge rating is 20 or lower. The creature is friendly to you and your companions for the duration and acts immediately after you on the initiative order. The DM has the creature’s statistics and controls the creature, resolving all of its actions and movement.

If the spell becomes permanent, the creature may remain friendly toward you depending on how it was treated.

Creature into Object. If you turn a creature into an object, it transforms along with whatever it is wearing and carrying into that form. The creature’s statistics becomes those of the object, and the creature has no memory of the time spent in this form if it reverts to its normal form. The object cannot be worth more than 10,000 gp.

Ref: ELCR p105