Can I put pickles and onions on my compost pile?

No, I’m not trying to make some compost delicacy. I’ve got a bunch of pickles I picked up in NYC, plus a bunch I made myself that are going south. Can I toss them into my compost pile or will there be too much salt for the health of the pile?

Also, I heard that onions are bad for the pile due to the fact that earthworms don’t like them. Should I stop putting onions on the pile?

It depends on the size and status of your pile. A hot pile of minimum 1 cu.yd. will easily handle the addition. The brine should be disposed of separately. An effective herbicide, that.
Onions are fine in compost; if you have earthworms in it then it never got hot initially or they are refining post thermophilic processing.

I always put the ends and peels of onions in mine, and they seem to compost just fine. All the pickles I get I eat, so I have no experience with them.

Thanks for info, I’ll go ahead and toss the pickles onto the pile and see what happens.