Heat olive oil in a large heavy skillet over medium heat. Add onions and 1/2 teaspoon salt.
Cook for 35 to 45 minutes, stirring often and lowering the heat as needed, until the onions are deeply brown and soft. Transfer half to a plate for garnish.
Cook the Lentils and Rice:
Combine lentils with 3 cups water in a saucepan. Bring to a simmer and cook for 15 minutes; the lentils should still be firm in the center.
Stir in rice, remaining 1 cup water, cumin, salt, pepper, and the onions left in the skillet. Bring back to a simmer.
Cover, reduce heat to low, and cook for 18 to 20 minutes, until rice and lentils are tender. Rest covered for 10 minutes.
Serve:
Fluff gently with a fork, spread on a platter, and top with the reserved caramelized onions.
Notes
Brown or green lentils hold their shape better than red lentils.
If the onions begin to catch before they soften, add a tablespoon of water and lower the heat.