Which type of Tomato should you grow?
Arguably the easiest type of tomato to grow in a pot at home is the Bush Cherry Tomato variety. These produce a lot of fruit even from just a single plant, so are the perfect choice if you're short on space. Unlike upright-growing varieties of tomato, they don't need to be trained, nor do you need to remove their suckers, and they can handle smaller pots.
However, it should be noted that as a general rule, tomatoes prefer larger pots and can struggle in pots that are too small. It's better to have a slightly too big a pot than one that is too small for these plants. Around 10 liters (2.5 gallons) is an adequate size for common types.
The one thing you can't compromise on is sunlight - tomatoes need plenty of sun in order to grow successfully, preferably around 6-10 hours of full sun per day. Without this, it's unlikely that your plant will produce fruit.
To offset this, they also need frequent watering so that their soil stays consistently moist (but not too wet) at all times.
Common problems with potted tomatoes
Although potted tomatoes are a great introduction to vegetable gardening, they can still potentially have some issues. Once you've got the hang of their care needs, though, you'll be rewarded with delicious fresh fruits, plus they're easy to take cuttings from and propagate, so it's totally worth the effort!
POT SIZE Tomato plants are sensitive to their pot size - too big or too small, both can cause them not to grow correctly. If the pot is too small, the roots will be compacted together in a way that prevents them from being able to uptake water or nutrients from the soil which, if left untreated, can lead to the plant's death. On the other hand, though, immediately planting your small tomato plant into an excessively large pot for it to 'grow into' isn't always a good idea either. For a plant that's in too big of a pot, the soil may dry out too slowly, which can lead to overwatering and root rot. You should think of plant pots as being a bit like children's clothes - you buy new ones as they grow, and so you should repot your tomatoes as they grow too.
HEAT Even though tomatoes like (and need) the sun, they can suffer in the intense summer heat that comes along with it. Too much warmth can cause the soil to be heated from all sides, which in turn makes it dry out faster and evaporate water at a faster rate too. Dried out soil causes stress to tomato plants, sometimes even to the point where the plant dies, so you'll need to water regularly to counteract this.
FERTILIZER IMBALANCE Generally, plants use a lot of energy to produce fruits, meaning they need a lot of nutrition in order to do so successfully. Therefore, if you start to notice that your tomato plant's leaves are yellowing or it's not producing any fruits, it may be a sign that it's not getting enough fertilizer (although it should be noted that yellow leaves can also be caused by other problems, such as overwatering).
PEST INFESTATIONS Unfortunately, potted tomatoes can be susceptible to developing pest infestations such as aphids and spider mites. Make sure to regularly check on them to keep an eye out for signs of pests - catching them early is key to successfully eliminating them.
BLOSSOM-END ROT It can be incredibly frustrating when growing tomatoes to notice that your otherwise healthy-looking fruit has a large, bruise-like blotch on the base of the tomato. These large spots are often brown in color and sunken into the fruit. This is Blossom-End Rot, and it sometimes seems to appear out of nowhere. It's usually caused by a lack of calcium, but can also arise as a consequence of becoming root-bound and / or being exposed to excessive drought.
Luckily, though, it's easy to both prevent and solve - the first thing is to check that you're watering consistently and using similar amounts of water each time. I.e. if you water very heavily one time and then sparsely the next, this can still affect your plant's health even if you're keeping the actual interval of watering consistent. You should also check that your plant isn't suffering from nutrient deficiency - switching to a better quality soil (with an ideal pH of around 6.5) is a good way to provide your tomatoes with enough calcium.
BLIGHT Blight is a serious disease that can affect tomatoes (as well as other plants such as potatoes). It's a common fungal disease that can quickly spread between plants and will gradually kill the fruits as well as the tissue within the stems and leaves. However, if you catch it early enough it is possible to prevent it from spreading.
The initial signs to look out for are small brown spots on your tomato plant. These will start out on the leaves and then eventually spread to the first fruits as the disease progresses - if you notice that the plant is becoming discolored (first yellow in color, then brown as it begins to die off), you should give your tomatoes a thorough check over and remove any affected tissue. Note that the fungal spores spread very easily (including by rainsplash and wind), so it's important to carefully dispose of the diseased tissue to prevent further spread.
In order to prevent Blight from taking hold again, be careful when watering to ensure that water doesn't get on the leaves. Water buildup on foliage encourages mold growth and can then drip down onto the soil, spreading the spores through this dripping.