Preheat the oven to 450°F.
In a large bowl, combine the quartered tomatoes, chopped onion, whole garlic cloves, salt, red pepper flakes, and sugar.
4 pounds Roma tomatoes, 1 cup onion, 6 cloves garlic, 2 teaspoons sea salt, 1 teaspoon red pepper flakes, 1 teaspoon sugar
Add the olive oil and toss until the tomatoes are well-coated.
½ cup olive oil
Transfer to a 13- × 9-inch baking dish.
Roast until the tomatoes soften, about 45-60 minutes.
Remove the pan from the oven and allow to cool slightly.
Drain off any excess liquid.
For a chunkier sauce, mash the tomatoes with a potato masher right in the pan. For a smoother sauce, transfer to a food processor and process for a few seconds.
Stir in the fresh basil and oregano.
¼ cup fresh basil, ¼ cup fresh oregano