It depends on
A: The printer
B: The cartridges
I've never had any problem using reputable 3rd party cartridges in various Canon printers - they work just fine.
Epson printers can be a bit picky, but are usually OK if you buy good quality cartridges
HP printers are brilliant printers, but I've yet to find any 3rd party cartridges that work reliably for any length of time - I always take the pain and buy original
If you want a good supplier I can recommend these people :
https://www.choicestationery.com/
I've bought laser and inkjet supplies from them for many years.