Combine all ingredients in a saucepan over medium heat, bring to a boil.
Lower heat and simmer until onions are softened, about 10 minutes.
Use an immersion blender to puree harissa to desired consistency; leave slightly chunky or puree completely.
Prepare boiling water bath canner while sauce is cooking. Heat jars in simmering water until read to use, do not boil. Wash lids in warm soapy water and set aside with bands.
Ladle hot harissa sauce into a hot jar, leaving 1/2 inch headspace. Remove air bubbles. Wipe jar rim. Center lid on jar and apply band, adjust to fingertip tip. Place jar in boiling water canner. Repeat until all jars are filled.
Process jars 15 minutes, adjusting for altitude. Turn off heat, remove lid, let jars stand 5 minutes. Remove jars and cool 12-24 hours. Check lids for seal. They should not flex when center is pressed.