The State Pension
To be eligible for the State Pension you'll need at least 10 qualifying years of National Insurance contributions or credits. If you're self-employed, you will usually need to pay your National Insurance contributions through your self-assessment tax return. MoneyHelper has more information on the type of contributions you will need to pay, and the benefits those contributions pay for.
Although valuable, the State Pension alone is unlikely to maintain the lifestyle you've enjoyed before retirement, which is why SIPPs (Self-Invested Personal Pensions) are a particularly attractive option to the self-employed, or those who change their career regularly.