Shakespeare's "Romeo and Juliet" is a sort of ode or tribute or homage to youth and young love. On summer nights young boys and girls find their youth a burden because they can't sleep--and probably don't want to sleep even if they could. While the old folks in the play have been sound asleep and snoring away for hours, the young men are wandering the streets burning up their excess energy. In those times maidens were securely locked up to keep them away from these passionate young men for pretty obvious reasons. Juliet is such a prisoner. Romeo can leap over her wall to get a look at her--but he can't get any closer than that. Juliet hasn't been asleep either. Convention is telling her one thing and nature is telling her another.
The young people have stayed up so late that it is getting close to daybreak. That's the main point of all this talk about the sun and the moon. We can see the moon in the daytime, but it always looks pale white and lacks the gold color that makes it beautiful by night. We can estimate that the time is around five in the morning. Romeo uses a poetic cliche when he says that Juliet is the moon's maid. He compares Juliet to the sun and at the same time to the moon's handmaiden. Juliet is "far more fair" than the moon regardless of whether it is nighttime or broad daylight. That is why Romeo is comparing Juliet to the sun. Shakespeare is deliberately breaking with conventional poetic symbolism because comparing a girl to the moon is something that has been done to death by poets of Shakespeare's time and long before that.
When Romeo says, "Arise, fair sun," he is thinking both of Juliet and of the real sun. He is comparing Juliet to the sun as a deliberate flouting of poetic language, and he is also thinking that when the real sun actually rises, as it will do quite soon, then there is a better chance that Juliet will wake up and appear on the balcony. It doesn't occur to Romeo that Juliet is having trouble sleeping too--and for the same reasons. He is thinking that when she does appear on the balcony she will be such a beautiful sight that she will seem like the sun. Naturally her brilliance will kill the moon, just as the real sun is so brilliant that it shuts off the lights of all the stars and planets and will sometimes, but not always, shut off the moonlight completely. On this particular night the moon may be full and also very close to the earth, so it would be hard for the sun to obliterate the moon completely. We have all been struck by seeing a big, white full moon in the sky when it is the middle of a bright summer day.
What Romeo says about the moon being sick and pale with grief is nothing but a poetic conceit. He is trying to flatter the girl he loves with extravagant praises. It is a poetic conceit on the part of Romeo and, of course, a poetic conceit on the part of his creator William Shakespeare. The moon is actually losing its gold color and turning white, or pale, because the sun is rising and the sky is getting brighter.
Perhaps the most striking thing about this famous balcony scene is that it is getting close to daylight and these young people--so enviably to us older types--are not even thinking about going to bed. They are full of sublime youthful exuberance and the stirrings of sexual passion. One of the characters in a William Faulkner novel, an old man, speaks this way of youth:
To be young. To be young. There is nothing else like it: there is nothing else in the world.
--William Faulkner, Light in August
As pointed out in other answers, Romeo is referring to Juliet here. He is looking up to her window when she appears. He compares her appearance to the rising of the sun which extinguishes the darkness of night.
As he does several times in the play, Romeo here compares Juliet to a strong light. He continues this theme later in the same speech when he remarks fancifully on her eyes being not as bright as stars but actually stars: stars that have exchanged places with her eyes in the heavens. He goes on to muse that if these stars are indeed now in her head, then 'the brightness of her cheek would shame those stars/as daylight doth a lamp'. Again, Juliet is associated with a bright light which eclipses that of the brightest stars. By the same token, he remarks that if her eyes were in the night sky, they would shine so brightly that the birds would be fooled into thinking it was daytime and start to sing: 'her eyes in heaven/would through the airy region stream so bright/that birds would sing, and think it were not night'.
In his use of imagery in this speech, Romeo paints a picture of Juliet as an dazzling, irresistible natural force which outshines everything else. It is interesting to note as well that he starts out by saying that Juliet is the moon's 'maid'. Traditionally, the moon has often been associated with femininity: particularly female charm, delicacy and beauty, while the sun is more associated more with the male element in many cultures. Here, though, Juliet's power is said to be such that she easily outshines the moon and her light is seen to be at least equal to that of the sun.
In order to fully understand the passage, you need the preceding lines:
But soft, what light through yonder window breaks?
It is the East, and Juliet is the sun.
Here Romeo is looking up at the window to Juliet's bedroom. Shakespeare is using a metaphor to compare Juliet's beauty to the rising sun.
Arise, fair sun, and kill the envious moon,
Who is already sick and pale with grief
That thou, her maid, art far more fair than she.
When the sun rises, it "kills" the darkness of the night. The moon is personified as being so envious of Juliet's beauty that it is "sick and pale with grief" that Juliet is "far more fair" than the moon is. In other words, Romeo is saying that Juliet is pretty hot! By telling the sun (Juliet) to "arise", Romeo means that he wishes that Juliet would come out onto the balcony to light up the night.
There is an in-depth explanation of this entire quote in the Shakespeare quotes section.
Juliet come out and brighten my world/take away my grief