Metastatic tumors with an uncertain primary site can be a difficult clinical problem. In tens of thousands of patients every year, no confident diagnosis is ever issued, making standard-of-care treatment impossible. Gene expression profiling (GEP) tests currently available to analyze these difficult-to-diagnose tumors have never been directly compared with the diagnostic standard of care, immunochemistry (IHC). This prospectively conducted, blinded, multicenter study compares the diagnostic accuracy of GEP with IHC in identifying the primary site of 157 formalin-fixed paraffin-embedded specimens from metastatic tumors with known primaries, representing the 15 tissues on the GEP test panel. Four pathologists rendered diagnoses by selecting from 84 stains in 2 rounds. GEP was performed using the Pathwork Tissue of Origin Test. Overall, GEP accurately identified 89% of specimens, compared with 83% accuracy using IHC (P=0.013). In the subset of 33 poorly differentiated and undifferentiated carcinomas, GEP accuracy exceeded that of IHC (91% to 71%, P=0.023). In specimens for which pathologists rendered their final diagnosis with a single round of stains, both IHC and GEP exceeded 90% accuracy. However, when the diagnosis required a second round, IHC significantly underperformed GEP (67% to 83%, P<0.001). GEP has been validated as accurate in diagnosing the primary site in metastatic tumors. The Pathwork Tissue of Origin Test used in this study was significantly more accurate than IHC when used to identify the primary site, with the most pronounced superiority observed in specimens that required a second round of stains and in poorly differentiated and undifferentiated metastatic carcinomas.