Endings for Salt and Sanctuary are noted in this page. This is of course spoiler-heavy so only consult the contents if you are ready for them.
The game ends if the player proceeds through the hallway after defeating the last boss: The Nameless God. You will enter a dark area with a well, and (if you talked to the Scarecrow at each location) a scarecrow that represents the god. Your actions at this point determine the ending. After doing one or the other ending, you will be thrown into the credits and then New Game Plus, starting from the beach.
Ending 1: Salvation
Escape the island.
You may choose this ending by ignoring the scarecrow and going down the well instead. The ending dialogue is determined by your Creed:
The Three (Born of Salt / Devour'd by sea / From icy crypt / Deliver me)
Devara's Light (Ageless solace / Clasp'd by death / Curs'd no longer / Gasping breath)
The Iron Ones (Will of man / steel and stone / Wrest from sea / For iron home)
The Stone Roots (Strangl'd roots / In blackest sea / Shed chains of steel / 'Til vines grow free)
Keepers of Fire and Sky (Stifled flame / In sea of ice / Looking tow'rds / Eternal sky)
The House of Splendor: (Bearing gold / On failing flesh / freed from gaol / to splendid rest)
Order of the Betrayer (Viceroy of / Our god of blood / Spreading strife / In lands above)
Ending 2: Domination
Become the new lord of the island.
This ending can only occur if you have spoken to the Scarecrow at every location it appears in throughout the game. If this is the ending you're after, you can backtrack to the location it should have shown up next. To choose this ending, you'll have to speak to the scarecrow a final time, and choose "take helm". This will convert you into the new Nameless God, ruler of The Island. You will obtain the Overlord Armor. Like the first ending, the dialogue you see is determined by your Creed:
The Three: (Burning cities / Bruis'd by war / Praise not the Three / I am the Fourth)
Devara's Light (This pantheon/ Of timeless gods/ Shall tremble at/ The spreading dark)
The Iron Ones (Superstitions / Fleeting gods / Crush'd and hewn / On bloodied rocks)
The Stone Roots (Ocean Black/ Invader's Blood/ Icy Sea/ To Wrathful Mud)
Keepers of Fire and Sky (Pow'r immense/ Searing cold/ Sky above/ And dark below)
The House of Splendor (Love of gold / Bitter heart / Plunge this splendor / Into dark)
Order of the Betrayer (Heart of Malice / Sewn in steel / Mete the master's / Wicked will)