As it is known, robots are creations of science. So when you got a robot who can cast magic, which is usually at odds with science (even if they can go hand-in-hand), it becomes a pretty novel sight and comes up with plenty of strange implications.
A lot of magic in fiction requires the caster to have some metaphysical connection with magic—usually a soul—in order to use it. A robot capable of using magic, therefore, has enough of a Heart Drive to meet this requirement, according to some works.
For this to count, Clarke's Third Law should not be in effect (i.e. the magic shouldn't be some very highly advanced technology), and the character has to be explicitly robotic from inception (ergo cyborgs don't qualify for this trope: they count as Cyborg Wizards instead). Since Tropes Are Flexible, if an Artificial Intelligence somehow has supernatural powers, they count for this trope too since it's that intelligence rather than the artificial body that makes a robot what/who they are.
Sub-Trope of Magitek, which is not limited to robots, and Science Fantasy. Also a case of Ninja Pirate Robot Zombie, being a combination of two things we consider cool, and Oxymoronic Being and/or Paradox Person, due to technology and magic mixed together.
- In Eberron, Warforged can be wizards and psions, just as easily as their meatsack companions. This is accomplished with the use of special Power Crystals inserted during their Creation, so it's kinda hard for them to multiclass into a mage later. That said, specific character examples are hard to come by, and most of these characters are likely going to be PCs.
- Shindroids in Final Fantasy D20 require taking an alternate Racial Trait (Magitek Device) during character generation to be magicians, giving up Composite Plating (a trait that gives them a higher Natural Armor score than meatbags) and Part Robot (Machine Empathy).
- Pathfinder: Androids — artificial humanoids with synthetic flesh and nanite fluid for blood, and who are created from Lost Technology automated factories rather than being born — can become spellcasters as easily as any natural race, and in fact tend to have keen interest in magic and spiritualism. The same is true in Starfinder with androids and SROs (Sentient Robotic Organisms).
- In Promethean: The Created, the Unfleshed are a kind of Promethian (a pseudo-living creature usually created from human corpses subjected to a specific ritual) arisen from broken machines rather than dead people. These can still use magic-like Refinements, using the Divine Fire imbued into their beings, in an effort to cure their Pinocchio Syndrome.
- Bravely Second: The E-Type models of the Glanz Empire's Iron Man soldiers are partially built using magic charms and are capable of casting spells like Lightning, thanks to having magic stones inside them that allow them to do so.
- Chrono Trigger: Averted with Robo (a sentient robot found in the Bad Future). While his techs can deal Shadow, Fire or Lightning damage, as well as heal, they are explicitly technological in nature; taking him to see Spekkio at the End of Time will confirm he can't use actual magic.
- Dragalia Lost: Downplayed regarding Mega Man. He's classified as a wand user, who are known for magic-based combat, yet he utilizes his signature Mega Buster during gameplay rather being shown using whatever wand he has equipped, and his special moves are also weapons from his games. He is able to use special moves that are part of the wand he equips just like any other wand user however.
- Magical Girl Lyrical Nanoha A's Portable : The Florian sisters in The Gears of Destiny are Ridiculously Human Robots who are just as capable of using magic as the rest of the cast. This is not the case in the Reflection/Detonation duology, as they are changed to being Human Alien girls infused with nanobots instead of robots, and their particular magic system is stated to not actually be magic in the movie continuity.
- Mega Man X1: If you manage to find the secret capsule that contains the Hadouken powerup, Dr. Light's hologram says that the technique is powered by the soul, and X (despite being a robot) has a soul that's close to a human.
- Overwatch: While Orisa and Bastion have clearly technological abilities, that line gets blurry in regards to Zenyatta and presumably some of the other Nepalese Omnics, as the faith he follows apparently grants him levitation, and temporary invincibility, among other things.
- Persona: If one counts the use of Personas as magical, then Aigis definitely counts, as does her prototype predecessor Labrys as they were created with supernatural objects to give them personalities. Persona 5 Strikers has Sophia, an AI with the same ability.
- Planescape: Torment had an Evil Wizard Construct in the Mordon Maze.
- Ratchet & Clank: Quest for Booty: Being a robot space pirate didn't stop Captain Darkwater from laying a curse on his treasure and binding his soul to his body.
- Slay the Spire: The Defect is just as capable of using spells as any other player character.
- In Sonic Heroes, one of the robots in Hang Castle and Mystic Mansion is the Egg Bishop, which can cast a healing spell on any robots it is near, including itself. When flipped over with a tornado jump, the Egg Bishop becomes the Egg Magician, which retains the healing spell, and also casts a spell that can drain rings from any team players within range of it.
- Steam World Quest is full of steam-powered robots, yet there are those who can explicitly cast spells. The one in your party who can do so is Copernica, Instant Runes and all.
- RWBY: Only living things can generate Aura, which gives humans who master the power the ability to manifest their power as special abilities that can seem like superhero powers or even magic-like in function. Although Penny is a Robot Girl, she is the very first artificial creation that is capable of sustaining an Aura. In Volume 7, Penny becomes the unplanned successor to the Winter Maiden's powers when her robotic body makes her the only one capable of safely reaching Fria. Her compassion for the dying Maiden creates the intimate connection needed for the powers to pass to her, transforming her into a genuine magic-user.
- Adventures of Sonic the Hedgehog: In "The Magic Hassle", Coconuts, a robotic monkey, buys a series of magic tricks from Wes Weasley to catch Sonic and get on Robotnik's good side, since Robotnik always assigns him to janitorial work, which he hates. Among the things Coconuts buys are a disappearing spell, a ghost-conjuring kit, a mastodon bone that can turn things to stone, and a bad luck emitter. Coconuts even dons a wizard's hat and cape as he performs these magic spells. At the end of the episode, Weasley forces Robotnik to pay a 359 million Mobium I.O.U. debt, and Robotnik chases him and Coconuts away with the bad luck emitter.
- Family Guy: A Cutaway Gag in the Season 12 episode "The Most Interesting Man in the World" involves a Show Within a Show called "Wizard Robot and his less successful friend".
- The Transformers: The season 3 episode "Madman's Paradise" features as its villain a Quintesson that had been banished by his fellows as a heretic because he practiced magic. Granted, it's not clear if the Quintessons are fully Mechanical Lifeforms like Cybertronians or Cyborgs .