Grimoires, the culmination of a wizard's research, are the study of spell modification and improvement. A grimoire is different than a spell book, but they often go hand in hand, and can even sometimes be two separate parts of the same tome. Spellbooks are a place to store the methods and info needed to cast a spell. Grimoires are a text that either changes the function of a spell slightly, or improves it overall. They are never changed enough to be worthy of an entirely new type of spell.
After studying them for a certain amount of time a player's Wizard can learn the modified spell and prepare it as they would the original spell. At the beginning of their spell prep time they can choose their spell slot for either the original spell, or the modified version, they can't be changed on the fly.
While spell rulings will likely differ, I'll pick a common one here as an example:
Magic Missile, in the most commonly creates a magical energy blast deals a 1d4 of damage for each missle summoned, more misses are summoned per the caster's level, usually with a cap of 4 or so. Usually the spell also requires no rolls to hit, it just magically seeks the target and does the damage.
Grimoires that are a trade-off: (roll a 1d6)
1. Blood Magic Missile:
Using your own blood in the creation of the spell, you amplify it's damage. The damage of the missile is upgraded to the next dice, (so a d6 instead of a d4) but for each missile casted in the spell, you take a d4 of damage. (so if you cast 3 d6 missiles, you'll take 3d4 damage from blood loss.)
Pretty straight forward, right? do some more damage but take some in return.
2. Concentrated Magic Missile:
Instead of casting multiple missiles, you make a single, stronger missile, with an extra dice for every missile you would have casted otherwise, plus one. (so instead of 4 separate d4 missiles, you would make a single missile that deals 5d4 damage)
3. Ice Magic Missile:
Increases the damage to the next dice (d4 to d6 as before) but deals cold damage instead of it's normal, magicky kind. Probably looks like icicles or some rad shit too.
In pathfinder (I know, I know) Magic Missile deals force damage, which is effective against most monsters, so by making it cold or ice damage there's a greater chance things are resilient to it, but gives you more overall damage as a trade. (And rewards planning, if they find out a monster is weak to ice, they can prep this spell!) Feel free to replace this one with literally any other element or damage type.
4. Tangible Missile:
By tying the missiles to the material plane more closely, can make more of them. Double the amount of missiles you would usually make, but you need to make a successful ranged attack roll to hit each missile.
5. Bane Missiles:
When preparing the Magic Missile, designate a creature or humanoid type that the caster is familiar with, (may require a successful knowledge or lore roll) and the missile will deal +1 damage per missile to targets of that kind, and -1 damage to everything else. (So a Bane (Elf) Magic Missile will deal 1d4+1 to elves, and 1d4-1 to whatever else)
6. Non-lethal Magic Missiles:
Deal non-lethal damage, or just are incapable of killing. they always deal -1 damage per missile, however.
Combo-spells. If a player has multiple grimoires, they can often combine them for greater effect. Anything that upgrades hit dice stacks. So if they cast a blood and ice Magic Missile, they fire blood infused blood icicles, and it deals d8 for each missile instead of the d4. (they still only take d4 per missile in damage, probably)
Since these are strictly better, I usually make them much, much harder to find. If you aren't comfortable with, they can always upgrade the slot or cost of the spell. (If magic missile is usually a 1st level spell, now make it a 2nd or 3rd, or whatever)
(Roll a 1d4)
1. Hyper-Geometric Magic Missile:
Using sacred geometric shape the formation of the missiles, they have a greater propensity to cause more destruction The dice is just straight-up upgraded to the next level.
2. Revealing Magic Missiles:
If a target struck by a Revealing Magic Missile, they must make a will save or the caster will know their alignment (or maybe just a secret about them)
3. Razorite Magic Missiles:
When the missiles deal damage to a target, the target begins to bleed 1 point of damage for each missile struck with. It stops when the target receives magical heal or can take time to bandage themselves.
4. Goo Magic Missiles:
Deals damage, but also each missile leaves behind a heavy residue, adding ten pounds of weight on the target, per target. Can be washed off with water.
I hope you get the idea. Depending on the spell you can get pretty creative, have stone walls grow arms and attack, have a fog spell be made out of gelatin, make a Knock spell quite but also make your teeth itchy.
Grimoires have been a hit in my games, I jive with the idea of horizontal leveling (powering up in ways that aren't a level up). My players like the added strategy, and it can be a fun way to add flair and character to a caster. (Of course the powerful ice mage would make his magic missiles ice-themed.) Another thing is: grimoires can survive a player character's death. The caster may die, but his book collection lives on, and can benefit future casters in the party. This also gives magic users a desire to find ancient tomes an' shit which is a good thing.