Migraine and major depressive disorder (MDD) are common brain disorders that frequently co-occur. Despite epidemiological evidence that migraine and MDD share a genetic basis, their overlap at the molecular genetic level has not been thoroughly investigated. Using single-nucleotide polymorphism (SNP) and gene-based analysis of genome-wide association study (GWAS) genotype data, we found significant genetic overlap across the two disorders. LD Score regression revealed a significant SNP-based heritability for both migraine (h2 = 12%) and MDD (h2 = 19%), and a significant cross-disorder genetic correlation (rG = 0.25; P = 0.04). Meta-analysis of results for 8,045,569 SNPs from a migraine GWAS (comprising 30,465 migraine cases and 143,147 control samples) and the top 10,000 SNPs from a MDD GWAS (comprising 75,607 MDD cases and 231,747 healthy controls), implicated three SNPs (rs146377178, rs672931, and rs11858956) with novel genome-wide significant association (PSNP ≤ 5 × 10-8) to migraine and MDD. Moreover, gene-based association analyses revealed significant enrichment of genes nominally associated (Pgene-based ≤ 0.05) with both migraine and MDD (Pbinomial-test = 0.001). Combining results across migraine and MDD, two genes, ANKDD1B and KCNK5, produced Fisher's combined gene-based P values that surpassed the genome-wide significance threshold (PFisher's-combined ≤ 3.6 × 10-6). Pathway analysis of genes with PFisher's-combined ≤ 1 × 10-3 suggested several pathways, foremost neural-related pathways of signalling and ion channel regulation, to be involved in migraine and MDD aetiology. In conclusion, our study provides strong molecular genetic support for shared genetically determined biological mechanisms underlying migraine and MDD.