In order to apply for an ICP licence the first step would be to incorporate a company in Mainland China. Foreign companies need to find a local Chinese partner who will have a controlling share of the Chinese incorporated company.
You can then apply for a license from the PRC Ministry of Industry & Information website http://www.miibeian.gov.cn/, you will need to create an account by verifying your email address and phone number first. Once registered on the website you will gain access to the ICP Licence request form, download the form, fill in as appropriate with your personal, company and hosting or CDN companies details, including your desired domain name and a description of your website.
Applications are not guaranteed to be accepted and can take from 30 – 90 days depending on the nature of the business you wish to be conducted in Mainland China.