Turn Instant Pot to Sauté mode. Add olive oil and cook the ground beef until browned, breaking it up as it cooks (about 4–5 minutes). Add the diced onion and garlic, and sauté for 1–2 minutes more until fragrant.
Press Cancel to turn off Sauté mode. Spread the dry spaghetti over the meat in a criss-cross pattern to prevent clumping.
Pour the jar of pasta sauce and the 2 cups of water over the pasta, covering the noodles as evenly as possible. Add salt, pepper, and Italian seasoning. Do not stir.
Close the lid and set the valve to Sealing. Cook on High Pressure for 8 minutes.
When the cook time is up, perform a quick release of pressure. Open the lid carefully.
Stir the pasta and sauce together gently to combine everything fully. Let sit for a minute or two to thicken slightly before serving.