Put the tomatoes, shallots, garlic, chilli, lemon zest and juice, vinegar and pectin in a saucepan and bring to the boil.
Stir in the sugar, then continue to boil until the mixture reaches 103C (use a sugar thermometer for this; it should take about 20 minutes). (CAUTION: hot sugar can be dangerous. Keep your eye on the pot at all times.)
Remove the pan from the heat and stir in the basil. Set aside to cool for 20 minutes.
Pour the jam into sterilised jars, seal and set aside until completely cooled.