I would recommend you to wait until a child is at least 05 years old. It is believed that it is best for a kid to spend time and play with real objects that he can hold and feel.
Screen-based activities prevent him from doing this, So, the longer you wait, the better it will be for your child. However, in the 21st century you need a mix of both as you also need your kid to be tech advanced.
One more point, a child should play with computer ,smart phones and tablets o only under parental supervision.
Supervising your child when he is interacting with these gadgets gives you the opportunity to mould his experience. It will also allow your child to understand things in a better way.
In addition, I would also recommend no more than a half an hour per sitting for a four- to five-year-old, no more than an hour per sitting for a six- to seven-year-old.
Using gadgets from smal age is ok, for example in case of me and my brother that started when we were 4 yo (TV + computer) and we didn’t have any problems with addiction to them later. Besides we live in society where technology became a very necessary part of our life so gaining skils for using gadgets from early age is important too. There’s nothing bad in using tablet for example for watching cartoons, movies and playing games sometimes, there are also many educational virtual games like Duck’s Alphabet, Ballony Letters, Zebrainy ABCs https://itunes.apple.com/app/apple-store/id1165324239?mt=8 , Sesame Street etc. which are very useful for teaching kids various subjects too. They’re often recommended even by professional teachers because of that combination with gaining computers skills and learning certain subjects. But of course child’s time with gadgets should be always controlled by parents and buying a separate one in such small age isn’t a smart idea at all because there’s no such big need for them and small children can’t value price of that things. In my opinion the best age for buying them starts from 9-10 yo. And yeah, addiction to them in every age isn’t a good thing at all, that’s why using them even for teaching should be combined with various other activities too.