In sense of stability, RNA; because of its susceptibility to hydrolysis at 2' hydroxyl group and loose stability. comparatively DNA is more stable thus being the genetic material.
While RNA is thought to be the first nucleic acid molecule to form in the primordial soup from which life emerged, DNA achieves greater stability by being double stranded (thus also introducing a template for repair). HOWEVER both DNA and RNA take a number of different forms with very different stabilities.
A plasmid is a bit of circular double stranded DNA, which protects its ends from fraying. DNA chromosomes use long repeat sequences called telomeres to protect their ends from fraying (as they do withe every replication).
RNA can take a variety of forms from tRNA, which binds to itself and can shuttle amino acids to the translation complex many times, to the messenger RNA (mRNA), which can be degraded in the cell over time if not digested by enzymes (it will stick around for a fairly long time in the absense of RNase, which digests RNA), to viral RNA encoding viral proteins but encased in the virus itself.
On the lab bench, isolated DNA dried in a tube tends to last longer than isolated RNA (it is always a good idea to slap it in dry ice as soon as possible), but part of the reason for this is that there are many more RNase enzymes in our environment than DNase.
So the question is complicated. It depends on the circumstance.
Someone else might provide a chemistry perspective?