The most common form of financing is being employed as a doctoral student by the HEI that has admitted you. This is called being appointed to a doctoral studentship (doktorandanställning in Swedish).
This appointment corresponds to four years of full time employment for a doctorate and two years of full time study for a licentiate. The university has to offer full time employment, but you can request to be employed at a lower rate, the minimum being 50%. The employment can be stretched over a period of maximum eight years. However, in some circumstances, due to sick leave for example, the employment can last longer.
The Higher Education Ordinance sets limits on the length of the appointment, with the appointment usually being renewed after the first year, and then every year or every second year.
As part of this type of employment you may have departmental duties (institutionstjänstgöring), such as teaching for example. The time allocated to these duties is not taken out of your years of full time employment – you get your doctoral studentship prolonged for such duties. You can read more about prolongation here.
It is important to note that financing of the doctoral student and funding of the research are separate matters. If you are hired to do research that is funded through an external grant to your supervisor for example, your compensation is planned for the full duration of the studies. This means that even if the funding of the projects runs out, your salary will not. It is also important to note that in this scenario you are an employee of the university, not of the project.
On a doctoral studentship, you have all the rights of an employee at the university.
You will most likely be part of a collective agreement, negotiated between the university and the trade unions. These agreements strengthen your protections and benefits as an employee, and they also set your salary. There is no legal minimum wage, rather the salaries are negotiated by the unions. To get an idea of what doctoral student salaries usually are, you can look it up on the websites of universities, or trade unions. Collective agreements usually regulate a progressive increase in salary over the duration of your studies, with several “salary steps”.