As Dale says, you probably shouldn’t be tallying up every gold piece in each and every encounter—the players’ wealth is meant to be very roughly what the guidelines say, sometimes above, sometimes below, but always kind of “around there.” And if it happens that the players aren’t “around there,” that’s not necessarily too big a problem either—all the wealth guidelines would have you do is fix the imbalance. We have a Q&A about how to go about doing that.
But while “don’t worry about it” is pretty good advice, I think it’s possible to give better advice. You shouldn’t worry about it, you shouldn’t tally everything up, but you should still have an idea roughly how much value you’re handing out and how that squares with the guidelines. And since your uncertainty could potentially result in a 100% difference in “value” ascribed to the loot, that’s a pretty big deal. I think the question needs a better answer.
So here goes: what you want to do is try to figure out how much an item is worth to the player. Ultimately, wealth in Pathfinder is an axis of character power, just like level is. The reason you care about how much wealth the players have is because it affects how much power they have, and you don’t want to overpower or underpower them. You want to evaluate how much power they are getting out of their items.
(For the purposes of this answer, I’ll be using “sale value” to refer to how much the players could get for selling it—that is, half of its “full value.”)
In a perfectly efficient system, where players can always sell the items they don’t want and buy the one they do, all items are worth their sale value at a minimum. Particularly when the loot includes items you know the players aren’t going to use—like nonmagical weapons when they already have powerful magic ones—you should just think of them as being worth their sale price, half their value.
But most games don’t let you sell anywhere you like, nor buy anywhere you like, nor necessarily buy anything you like. This is where the concept of wealth being a long-term trend rather than a precise measure of exactly how much the players should get and have at every point in time comes into play. If your players need to wait until they return to town to sell their loot and buy things with their earnings, then in the interim, they are “under” where their wealth should be. Items they aren’t using have zero value to them during that time. Even gold itself isn’t worth its weight in gold until you actually get to buy something with it. But for the most part, that is fine—as long as they get to town sooner or later, they will eventually get their value out of those items, and that’s good enough for maintaining the long-term trend.
But that still only applies to items the players sell rather than keep. Items the players keep are worth, in their estimation, more than they could sell them for—or else they would sell them. Does that mean they are worth their full value? Maybe, maybe not—it’s entirely plausible to keep an item you find that you wouldn’t have bothered to buy yourself. Then its value is somewhere in between its sale value and its full value.
Or you could have an item that is absolutely perfect for a character, completely dear to them and not something they would ever willingly part with—and not just for sentimental reasons, either. Then you have something that may well be worth more to the player than its full value. In fact, everything the players buy—kind of by definition—is worth more to them than they paid for it (or else they would not have done so).
For the most part, these two situations (keeping a found item you wouldn’t buy, valuing an item more than it would cost you to buy it) aren’t going to change matters too much. You would only have to worry about them in extreme cases. But I think it’s good for a GM to keep some perspective on what really “counts” for an item’s value.
More practically, I recommend thinking of loot that you expect the players to use as being its full value, and thinking of loot you expect them to sell at the first opportunity as being worth its sale value (i.e. half). If they surprise you either way, they have basically thrown off their wealth relative to your estimates—but probably not by very much. If it turns out to be a big difference, again, see the link above.
The only time I would recommend getting more involved is when something weird happens—usually some extremely long stretch where players are not getting items they will use, and cannot buy the items they want. If that goes on for several levels, and they aren’t using items and amassing a lot of items to sell and/or gold they cannot spend, they are falling lower and lower in “real” wealth relative to their level. That can be a problem, and you might have to, basically, ignore their gold and loot for the purposes of considering their wealth, and balance things accordingly. Note that if it goes on long enough—quite long—this can get very difficult to balance, because being under-item’d is a much bigger problem for, say, martial characters than it is for spellcasters.