The Locofoco Party, formed in 1835, was a radical branch of the Democratic Party, opposed to hierarchies, banks, monopolies, tariffs, paper money and anything else they believed went against the principles of democracy by conferring special advantage on a favored few. They took their name from the new self-igniting matches they used to illuminate their meetings after their Tammany opponents attempted to sabotage them by turning off the gas lamps.
Hawthorne had been accused of being appointed to his position in the custom house on the basis of his “Locofocoism” in the Boston Atlas only a year before The Scarlet Letter was published. The Salem Register, however, took pains to distinguish him from his more politically radical colleagues, saying, “we should be sorry to rank him with his temporary associates, the clique of plotters who have made themselves so offensive as public officers” (11 June, 1849). The entire article can be read here, and you can read more about the Locofocos here.