DNA is in the nucleus and stays there. RNA can go inside and outside the nucleus. The RNA takes an encoded blueprint from the nucleus to the ribosome which decodes that information to make proteins.
DNA is the blueprint for proteins, and RNA is the messenger.