Depends on the area, but my mother in law put in a septic and drain field this past summer and it was $6500. Wells depend on the depth and type of soil encountered in drilling it. We put in a 5" well 3 years ago, hit water at 52 feet and spent about $5000.
Ten years ago I put in a well (through two layers of bedrock, 300'+) $5000.00. The entire septic system was another $24,000.00. That was in Wisconsin, ten years ago. Now, just a faulty leach field, just a portion of an existing septic system, could cost you $20,000.00.