FWIW, I've served as safety pilot for someone who was working through their instrument training at the same time I was. It worked well, we did the pro-rata share thing. It was a 2 leg trip, we swapped roles on the way back. We were in the same flying club, at similar stages of training and our CFII (who we had in common) recommended we fly together.
I would advise using caution, however, as acting as PIC and safety pilot for someone who you don't know very well. Having 2 strangers without CRM training operating as a crew is challenging. If the person manipulating the controls flies poorly or has a deviation, the person ACTING as PIC is going to come under scrutiny (as they should, that is the responsibility of a person acting as PIC). I've found it much more relaxing to simply act as safety pilot, but NOT act as PIC, not log any of the time, AND not pay for that time. I'm there to look out the window and make sure you don't hit the ground, or another plane, and (optionally) to give you a friendly nudge if I believe there's a lateral or vertical deviation in the works and you're not likely to catch it any time soon (that last part is tricky).
Communication ahead of time is key. The need for this is not obvious until you've been on the wrong side of it. It's not so much of an issue if you're flying with someone with whom you regularly fly with and have established a routine. It's very different if you're going up with a relative stranger. There should be a detailed conversation along the lines of, "this is what I am looking for you to do...."