Homura is a magical girl who first appears in an apocalyptic nightmare of Madoka's. She transfers into her school the day after the dream. She is a beautiful, mysterious individual that performs exceptionally well in academics and athletics. This makes her instantly popular even though she is cold to others.
She seems to know Madoka well and wishes to prevent her from becoming a magical girl. She attacks Kyubey in the first episode, only to be stopped by Mami.
Homura's cold personality developed from repeating the same timeline again and again. She was originally a shy, weak transfer student who spent a long time in hospital due to a heart disease. She was befriended and eventually saved from a witch by Madoka, who revealed that she was a magical girl. When Madoka was killed in her battle with WalpurgisNacht, Homura contracted with Kyubey to become a person that could protect her. She became a magical girl with the ability to manipulate time, allowing her to return to her first meeting with Madoka in order to change her fate. She tries again and again to prevent Madoka from being killed or becoming a magical girl and, inevitably, a witch, but is never able to save her. She always returns to the beginning of the month upon failure.
Her magical weapon is a shield filled with sand that allows her to freeze time. However, this power becomes useless if she is physically restrained as she cannot turn her shield to activate it. She can also use this shield to block projectiles and store the various weapons she carries. Since her shield and magic have no offensive capability, she instead attacks using stolen firearms and homemade explosives while time is stopped. Once the sand on her shield runs out, Homura must reset the timeline.
*REBELLION SPOILERS BELOW*
In rebellion, Homura extracts Madoka's human form from Law of Cycles and then rewrites the world. She calls herself "Devil", though her power comes not from grief but from love. She creates a new timeline where Madoka transfers to Homura's school and Sayaka and Momoe Nagisa are alive.