James Madison thought so. In fact, the laid out the blueprint for battling unconstitutional federal actions in Federalist 46 before the Constitution was even ratified.
Should an unwarrantable measure of the federal government be unpopular in particular States, which would seldom fail to be the case, or even a warrantable measure be so, which may sometimes be the case, the means of opposition to it are powerful and at hand. The disquietude of the people; their repugnance and, perhaps refusal to cooperate with officers of the Union, the frowns of the executive magistracy of the State; the embarrassment created by legislative devices, which would often be added on such occasions, would oppose, in any State, very serious impediments; and were the sentiments of several adjoining States happen to be in Union, would present obstructions which the federal government would hardly be willing to encounter.
In fact, northern noncompliance with the Fugitive Slave Act of 1850 was so effective, several southern states specifically cited northern “nullification” of the law in their declarations of causes supporting secession.
And we have seen large-scale noncompliance effectively nullify federal marijuana laws across the U.S.