*All quotes are taken from the Norton Shakespeare, based on the Oxford Edition.
In Act I, Scene 2, a bit of history is revealed. Ariel is reminded that Prospero's magic saved the sprite from a terrible situation (good). Even though Prospero believes this to be a good deed, the sprite is still being held against his will (evil). Before Prospero intervened, Ariel was forced into slavery by a witch.
Caliban, the witch's deformed son, is also under Prospero's command. Here Prospero uses his magic forcefully, threatening Caliban with it: "If thou more murmur'st, I will rend an oak,/And peg thee in his knotty entrails till/Thou hast howled away twelve winters." (296-298)
In act V, Scene 1, Prospero's magic has held the passengers prisoner (evil), but out of harm and out of the elements (good). Although the act of the tempest culd be seen as evil, Prospero never physically harmed any of the men.
The wreck has caused the passengers to endure sorrow for those they believe to have lost.
Ariel tells Prospero that the men's mourning could even affect Prospero: "Your charm so strongly works 'em/That if you now beheld them your affections/Would become tender." (17-19)
The good that comes out of the magic is that Prospero is willing to give up the practice once all the spells are removed.
Magic can be used for both good and evil purposes in The Tempest because magic is like any tool or weapon: it is essentially neutral. It's mainly a way of multiplying the power of those who use it.
You therefore have to look at how the magic is used, and who uses it, to see if it is used for good or evil.
For example, in Act I we see that magic can be used to imprison beings. To be specific, Sycorax trapped Ariel. That seems clearly dark or evil. By contrast, Prospero frees Ariel.
In Act V, in Prospero's long speech, we hear an account of all that Prospero did with his magic. If anyone who was evil opened graves and woke the dead, the results would be very dark indeed.
However, to really see how magic works for good, we need to look other places in the play. Prospero creates a storm in Act I…for justice. Prospero sends Ariel to confuse the shipwrecked…for justice, so he and Miranda can have their rightful places again. Then he sets the magic aside.
In Act I, scene ii the magic of Prospero and the witch Sycorax are starkly contrasted. Sycorax used magic for evil purposes, imprisonling Ariel for twelve years in a "cloven pine." It is even speculated in the story that Sycorax has the devil himself behind her magic. Prospero, on the other hand, uses his magic for good. He frees Ariel from his prison and tries to help him.
In Act V, scene i Prospero discusses with Ariel how magic is best used in virtue, or in honest situations, rather than in vengance, or for moraly reprehensible reasons driven by anger, fury, or revenge.
"Yet with my nobler reason 'gainst my fury
Do I take part: the rarer action is
In virtue than in vengeance: they being penitent,
The sole drift of my purpose doth extend
Not a frown further. Go release them, Ariel.
My charms I'll break, their senses I'll restore,
And they shall be themselves."
In Act I, scene 2, Prospero explains that he used his magic to create a storm (which we saw in scene 1), which was terrible in itself but which is used for good ends: to reach/create justice for Prospero and Miranda by revenging himself on the king and duke.
In Act V, scene 1, Prospero has Ariel bring forth magic music to calm the visitors to the island and sooth their minds.
To be honest, I'm not sure that either shows pure good or pure evil, but rather, a search for justice via revenge and a willingness to show compassion via magic.