It runs generally north in the states of Minas Gerais and Bahia, behind the coastal range, draining an area of over , before turning east to form the border between Bahia on the right bank and the states of Pernambuco and Alagoas on the left one.