Let $X$ be an algebraic variety over $\mathbb{C}$ (the ground field is not important but this makes things easier I think) and $G$ an algebraic group acting over it. Let's say we know that there's a normal subgroup $K \cong \mathbb{G}\_m$ such that $K$ acts trivially on $X$ and $G/K$ acts in a free way on $X$.


I think one could put less restrictive hypothesis on $K$ actually: maybe reductive should be enough.


I'm denoting as $\mathcal{X}=[X/G]$ the quotient stack. Is it always true that $$H^\*(\mathcal{X}) \cong H^\*(X/(G/K)) \otimes H^\*(BK) $$ and $$H^\*\_c(\mathcal{X}) \cong H^\*\_c(X/(G/K)) \otimes H^\*\_c(BK) $$
(everything is meant to be with $\overline{\mathbb{Q}\_{\ell}}$ coefficients.


What should be a possible counterexample?



Cohomology of quotient stack
Let $G$ be a linear algebraic group, and $K\subset G$ a closed normal subgroup with quotient $L = G/K$. So all three groups are linear algebraic. Further, assume $L$ is connected.


Let $X$ be a variety with $G$-action such that $K$ acts trivially, $L$ acts freely and we have a quotient $X/L$.


**Step 1:**  The canonical map $BG \to BL$ is a fiber bundle with fiber $BK$. As $L$ is connected the mondromy action on the cohomology of the fibers, namely $H^\*(BK)$, is trivial. Further, the Leray-Serre spectral sequence associated to this fiber bundle degenerates at $E\_2$ because both $BK$ and $BL$ have cohomology concentrated in even degrees.


Note: The claim about odd vanishing in cohomology holds because $K$ and $L$ are linear algebraic groups and we are using torsion free coefficients (it is ultimately due to the Bruhat decomposition). To emphasize: no connected assumptions are needed for this vanishing, just torsion free coefficients and linear algebraic groups.


**Step 2:**  We have a pullback square (this **claim** should be checked - I have not worked out the details carefully):
$\require{AMScd}$
\begin{CD}
[X/G] @>{}>> BG\\
@VVV @VVV\\
X/L @>{}>> BL
\end{CD}


The monodromy action on the cohomology of the fibers $H^\*(BK)$ for the bundle $[X/G] \to X/L$ is the pullback of the monodromy action in $BG \to BL$. Hence, it is trivial.


Further, the elements of $H^\*(BK)$ are permanent cycles in the Leray-Serre spectral sequence of $[X/G] \to X/L$ because they are so for that of $BG \to BL$. This gives the required claim:


$H^\*([X/G]) \cong H^\*(BK) \otimes H^\*(X/L)$.


Note: even assuming I haven't done something completely dumb above, this says nothing about ring structure. Further, the requirement that $L$ act freely on $X$ should be unnecessary - replace $X/L$ by $[X/L]$ (again, modulo me not being delusional).


The point (assuming the pullback square is correct) at the heart of the matter is that $BG \to BL$ is the **universal** example of a fiber bundle with structure group $G$ in which the $G$-action on the fibers factors through $L$ (i.e., $K$ acts trivially).


