The movie you're describing is The Conjuring (2013). It follows the Perron family who move into a farmhouse in Harrisville, Rhode Island and experience paranormal activity linked to the spirit Bathsheba. The film takes creative liberties but is inspired by the real-life case files of Ed and Lorraine Warren. It is distinct from The Amityville Horror and The Exorcist.