To stay in Sweden for more than 3 months as an EU citizen you need to have right of residence. This means that you must be studying, be employed, self-employed or have other means to support yourself.
Having right of residence, you do not need a residence permit to live in Sweden. If you have family members who are EU citizens, your right of residence also includes them. If you have family members who are non EU citizens, they need to apply for residence cards.
After having lived in Sweden for five years with right of residence or being a close relative to an EU citizen, you will be granted permanent right of residence. You can then apply for a permanent residence card, and you might also be eligible for Swedish citizenship.
If you have lived in an EU country more than 5 years and have stable and regular source of income , health insurance , have integrated properly with EU laws and regulation, you can get long term residence for that country. Persons who are granted long-term resident status receive a special EC/EU residence permit. This permit can grant you similar rights as an EU citizen giving them right to study, work get social protection and assistance (at least core benefits),have access to goods and services, etc or start their own business or live on their pension. If you are accepted for a long-term resident status in Sweden. You can change your status from that EU country to Sweden
Countries which are covered by the directive on residence permits for long-term residents
Austria, Belgium, Bulgaria, Croatia, Cyprus, Czech Republic, Estonia, Finland, France, Germany, Greece, Hungary, Italy, Latvia, Lithuania, Luxembourg, Malta, Netherlands, Poland, Portugal, Romania, Slovakia, Slovenia, Spain and Sweden..