Rinse the dried navy beans and soak overnight if desired, or use the quick soak method by boiling for 2 minutes and letting sit for 1 hour, then drain.
Heat olive oil in a large pot over medium heat.
Add diced onion, carrots, and celery and cook for about 5 minutes until softened but not browned, stirring occasionally.
Add minced garlic and cook for 30 seconds.
Add drained beans, ham bone or diced ham, bay leaf, dried thyme, black pepper, chicken broth, and water.
Bring to a boil, then reduce heat to low and partially cover.
Simmer gently for 90 minutes to 2 hours, stirring every 20 minutes, until beans are tender.
Remove the ham bone if using and shred any meat, then return the meat to the pot and discard the bone and bay leaf.
Taste before adding salt and adjust gradually as needed.
Mash about 1 cup of beans against the side of the pot and stir back in to thicken the soup.
Add hot water a little at a time if the soup is too thick.
Stir in 1 teaspoon apple cider vinegar at the end and taste before serving.