Forget about the age thing - 35 is nowhere near too old, and especially in IT, employers will hire you as long as you've got the skills. It's not like other industries. Your advantage is actually that you bring work experience and maturity to the table, while a lot of fresh graduates have zero practical sense. People start retraining programs like this way later and still land good jobs.
The real question is honestly whether you can stick it out for the next 2-3 years. A retraining program or apprenticeship is demanding - school, maybe lower pay in between, your brain has to get back in shape. But if you really push through it and actually get practical experience at the end (some programs have internships, make sure to check), then you'll have better prospects afterward than a lot of people. Demand for IT specialists is still strong, so even if the job market gets tougher down the line, you don't need to worry about your age.
What helps: Talk to the employment agency or career counseling services about publicly-funded retraining programs - some of them can get partial funding. Also chat with current IT specialists or check out forums to see what the process is actually like. If you notice that it genuinely appeals to you and isn't just an escape from retail, then it makes sense.