Let R be a commutative ring with identity and $${\mathbb {N}}_0$$ be the additive monoid of nonnegative integers. We say that a function $$t : {\mathbb {N}}_0 \times {\mathbb {N}}_0 \rightarrow R$$ is a twist function on R if t satisfies the following three properties for all $$n, m, q \in {\mathbb {N}}_0$$ : (i) $$t(0,q) = 1$$ , (ii) $$t(n,m) = t(m,n)$$ , and (iii) $$t(n,m) \cdot t(n + m, q) = t (n, m + q) \cdot t(m, q)$$ . Let $$R[\![X]\!]$$ (resp., R[X]) be the set of power series (resp., polynomials) with coefficients in R. For $$f = \sum _{n=0}^{\infty } a_nX^n$$ and $$g = \sum _{n=0}^{\infty } b_nX^n \in R[\![X]\!]$$ , let $$f+g = \sum _{n=0}^{\infty } (a_n+b_n)X^n$$ , $$f*_tg = \sum _{n=0}^{\infty }(\sum _{i+j = n}t(i,j)a_ib_j)X^n$$ . Then, $$R^t[\![X]\!]:= (R[\![X]\!], +, *_t)$$ and $$R^t[X] := (R[X], +, *_t)$$ are commutative rings with identity that contain R as a subring. In this paper, we study ring-theoretic properties of $$R^t[\![X]\!]$$ and $$R^t[X]$$ with focus on divisibility properties including UFDs and GCD-domains. We also show how these two rings are related to the usual power series and polynomial rings.