Yes, you can leave a contract anytime you choose, as long as you don't walk out during a shift with no word to your superiors. There is nothing a facility can do, because they also can terminate you at a moment's notice, as in, cancelling your contract.
That is the nature of travel or agency work. I work when I want and for whom. They employ me for a reason, and if that reason changes, it is in the contract that they can cancel me, without any recourse on my end. Same for them
They can TRY to make it hard, as in, not give you a recommendation, your agency refuses to work with you again (there are only...oh....500 or so to choose from now?), or they blackball you with the various VMS systems.
I have watched travelers no call and no show--nothing is done to them. I have friends who have gone to a facility and it was such a train wreck they felt their license was in jeopardy, called their recruiter and said..."I'm out"...and never went back--nothing is done to them. I personally have accepted two contracts, got to the signing portion only to find that the recruiter was trying to pull a fast one (a very common practice especially in CA) and I refused the assignment. No one can do a thing to me.
It a reputation thing for the most part. As long as you satisfy your nurse compact obligations...you pass off your patients---no employer can "do" anything to you but bad mouth you and try to make sure you don't get another job. What's it worth to you? Is your license at risk? RUN. These people don't pay your bills and would throw you under the bus in a microsecond if they felt you weren't being pliable.
By that I mean, a good number of these facilities that use travelers chronically are troubled in one way or another. Bad management, toxic work environment, low pay--and the reason that they can't keep staff is because most RNs run away from them as staffers. This means that this toxicity is transferred onto the traveler.
They also know that you are flying by the seat of your pants, you have no solid HR dept behind you (travel companies will also throw you under the bus if you endanger their contract with a facility, and all a facility has to do is claim that you have damaged this relationship)---and you are hired to be "beaten like a rented mule". I am being hyperbolic, clearly, but in the end, the staff is protected first and you as a traveler are ON YOUR OWN.
Personally, if I were at a facility that I just couldn't cope---I would tell the recruiter and the facility that I have a personal emergency in my hometown and I have to leave. Do it gracefully, don't comment on your way out---and be lucky you are gone.
At the end of the day, travel assignments aren't usually in glorious, wonderful, no hassle places. ON OCCASION you get the pregnancy fill in or the FMLA assignment, but those are so rare as to be the exception to the rule. The facilities are troubled...and you are going into what most likely will be a toxic situation. Most travelers know this...and this is the reason for the term "traveler friendly" that some recruiters like to throw around to get you to sign.
None of them are truly traveler friendly. Period. No travel company has your back. Period. No facility has any obligation to keep your contract or have your back. Period.
So if you want to cut and run, do it with some responsibility and go. No one can do a thing to you, but don't be shocked when your recruiter emails everyone they know that you didn't finish--and you are never allowed back to that health system again. Be sure you don't ever need either one.